This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Linux applications using RVDS

Note: This was originally posted on 28th July 2010 at http://forums.arm.com

hi

I  cross compiled some linux code using RVDS .

i used the instructions given in the following document

Building linux Applications using RVCT 4.0 and GNU tools

i used the latest CODE sourcery tool chain for this..


The compilation went through and it created a dynamically linked excuetable which uses shared libs.

My aim is to create a static excuetable which does not depend on any shared obj .

(basically something like gcc --static ) but i am not able to find such a option with armcc.

Kindly help

Regards
Sundar
Parents
  • Note: This was originally posted on 18th August 2010 at http://forums.arm.com

    Glad to hear it; you're welcome.


    That really depends on how much time your application spends in the libraries and how much in the armcc-built code.  Profiling with something like DS-5 Streamline or oprofile is probably the right place to start.  If you find out you're spending a lot of time in the libraries (for example memcpy) it might be worth trying to use those functions from the RVDS libraries -- but it can be messy or impossible if the library functions are OS-dependant (file i/o, signals, sockets, ...).


    Hi Scott

    Now i am stuck in another issue.
    I was able to build a static binary as mentioned . but now
    The binaries which i built are all seg faulting in the target.

    A statically linked binary segfaulting in the target baffles me :unsure:.

    Some details

    My target runs Angstrom linux . I used Code sourcery tools to cross compile for the target.

    Any light on this
    ?

    I have another question.



      Like you said the options in the config file are implicit options provided to the compiler. But now when i compile i give the path to the config file ( xml file) and there are some options in it which was automatically configured.

    You said it depends on the options which you give inthe comand line depending on which it will be decided that whether the options are to be taken or not.

    now armcc by default produces a static binary until u give the option --shared. Problem is my config file has this option called --shared which  is why it produces a dynamic lib. how can i tell the compiler not to take this option ? \

    If this works i need not work around using translate_gcc



    Thanks
    Sundar
Reply
  • Note: This was originally posted on 18th August 2010 at http://forums.arm.com

    Glad to hear it; you're welcome.


    That really depends on how much time your application spends in the libraries and how much in the armcc-built code.  Profiling with something like DS-5 Streamline or oprofile is probably the right place to start.  If you find out you're spending a lot of time in the libraries (for example memcpy) it might be worth trying to use those functions from the RVDS libraries -- but it can be messy or impossible if the library functions are OS-dependant (file i/o, signals, sockets, ...).


    Hi Scott

    Now i am stuck in another issue.
    I was able to build a static binary as mentioned . but now
    The binaries which i built are all seg faulting in the target.

    A statically linked binary segfaulting in the target baffles me :unsure:.

    Some details

    My target runs Angstrom linux . I used Code sourcery tools to cross compile for the target.

    Any light on this
    ?

    I have another question.



      Like you said the options in the config file are implicit options provided to the compiler. But now when i compile i give the path to the config file ( xml file) and there are some options in it which was automatically configured.

    You said it depends on the options which you give inthe comand line depending on which it will be decided that whether the options are to be taken or not.

    now armcc by default produces a static binary until u give the option --shared. Problem is my config file has this option called --shared which  is why it produces a dynamic lib. how can i tell the compiler not to take this option ? \

    If this works i need not work around using translate_gcc



    Thanks
    Sundar
Children
No data