9 Replies Latest reply on Dec 14, 2012 7:08 AM by @qq.com

    compile issue

    @qq.com

      Hello!

         

      I want to know how to use math function such as sin(). When I use sin(),my compie fail.It tells me I don't define sin(),but I have added math.h to my procedure

         

      Thank you!

        • 1. Re: compile issue
          ramav_01

          Hi comy,

             

          You also need to add libm.a in the linker path.

             

          Add "${ARMGCC_INSTALL_PATH}\arm-none-eabi\lib\libm.a" as shown in the attached figure.

             

          Thanks,

             

          sai krishna.

          • 2. Re: compile issue
            @qq.com

            That's all right. Thank you very much

            • 3. Re: compile issue
              @qq.com

              Excuse please. There is still a error that arm-none-eabi-gcc: SDK\1.2\\arm-none-eabi\lib\libm.a -mcpu=arm926ej-s -mthumb-interwork -g -gdwarf-2 -oUSBBulkLoopManual.elf: No such file or directory. Thus my compile fail again

                 

              I hope you can help me. Thanks!

              • 4. Re: compile issue
                ramav_01

                Comy,

                   

                Could you please check whether you have libm.a in the path SDK\1.2\\arm-none-eabi\lib\

                   

                If you don't have please place the attached libm.a there.

                   

                In my PC, I have that library file in the following path:

                   

                C:\Program Files\Cypress\ARM GCC\arm-none-eabi\lib

                   

                Thanks,

                   

                sai krishna.

                • 5. Re: compile issue
                  ramav_01

                  Please remove the extension .txt....

                  • 6. Re: compile issue
                    @qq.com

                    Hello!

                       

                    I have libm.a in the path which I install ,I don't know why it tells me there is no such file

                       

                    I do need your help. Thank you !

                    • 7. Re: compile issue
                      user_173869630

                      Hi,

                         

                      I observed a similar issue...
                      The path to the lib is somehow damaged!
                      In your error-message...

                         

                      "arm-none-eabi-gcc: SDK\1.2\\arm-none-eabi\lib\libm.a -mcpu=arm926ej-s -mthumb-interwork -g -gdwarf-2 -oUSBBulkLoopManual.elf: No such file or directory."

                         

                      ... there is missing the install-path of the Cypress-SDK, something like "C:\Cypress\"!!!

                         

                      You should check the content of the path-variable FX3_INSTALL_PATH which you can find in the system-properties of your PC => environment-variables!

                         

                      In my case the variable was even ok and I just could solve this issue by checking out my project again from our SVN-repository!

                         

                      Seems to be a problem/bug in Eclipse...?!

                         

                      So maybe you should delete the example project in Eclipse and import it again.

                         

                       

                         

                      Regards,

                         

                      Robert
                       

                      • 8. Re: compile issue
                        user_173869630

                        Oh, I just saw that you need an gcc-lib!

                           

                        Then you have to check the content of the variable ARMGCC_INSTALL_PATH instead of FX3_INSTALL_PATH, of course!

                           

                         

                           

                        Robert

                        • 9. Re: compile issue
                          @qq.com

                          I have found my fault. Thank you very much