naseeam
asked on
Why my code (program) build with old compiler?
My computer is running Windows 10 Pro, 64-bit. My C language files or my code (program) are stored in the hard disk.
The old and new version of WindRiver Diab Compiler are stored in Linux Server?
My bash profile used to contain path to old compiler. To compile, I ran Winscp to access Linux Server. Then, I dragged my C language project to Linux Server. I opened the command window from Winscp and invoked make program to build my executables. This all worked fine.
To build with new compiler, I changed path in my bash profile but my code (program) is still getting build with old compiler. The generated .map file shows path to old compiler.
My bash profile is stored in my windows desktop. Does Winscp read bash profile when it is invoked? How does it know to read bash profile from desktop? Why is my program not getting built with new compiler?
The old and new version of WindRiver Diab Compiler are stored in Linux Server?
My bash profile used to contain path to old compiler. To compile, I ran Winscp to access Linux Server. Then, I dragged my C language project to Linux Server. I opened the command window from Winscp and invoked make program to build my executables. This all worked fine.
To build with new compiler, I changed path in my bash profile but my code (program) is still getting build with old compiler. The generated .map file shows path to old compiler.
My bash profile is stored in my windows desktop. Does Winscp read bash profile when it is invoked? How does it know to read bash profile from desktop? Why is my program not getting built with new compiler?
ASKER
I don't know what kind of batch file is vcvarsall.bat.
I just need to build with the old compiler. From Winscp main menu, I went to Session - Disconnect. Then, I logged in but still program was built with old compiler?
How can I be sure path to compiler was exported to Linux server?
I just need to build with the old compiler. From Winscp main menu, I went to Session - Disconnect. Then, I logged in but still program was built with old compiler?
How can I be sure path to compiler was exported to Linux server?
ASKER
I mean I need build my program with new compiler.
invoked make program to build my executablesare you using a makefile? if yes post it.
if not check environment variables used by the build (make) they probably point to the old folders and the old compiler.
Sara
ASKER
Since it's company makefile, I can't post it.
Few lines from makefile are as follows:
COMPILER= -D __DCC__
WRV_CMP = C:\WindRiver\diab\5.9.4.8\ include\di ab
Macro WRV_CMP isn't being used. Macro COMPILER is being used. I think symbol __DCC__ applies to both versions of Windriver Diab Compiler.
How can I be sure the path to new compiler specified in bash profile got exported to Linux Server?
Few lines from makefile are as follows:
COMPILER= -D __DCC__
WRV_CMP = C:\WindRiver\diab\5.9.4.8\
Macro WRV_CMP isn't being used. Macro COMPILER is being used. I think symbol __DCC__ applies to both versions of Windriver Diab Compiler.
How can I be sure the path to new compiler specified in bash profile got exported to Linux Server?
Just make another user with another bash profile for another compiler.
ASKER
I made another bash profile for another compiler but I don't think I have access to make another user. Currently, I don't have admin rights on my computer. Our IT Department controls creating users.
Macro WRV_CMP isn't being usedmacros can be used by other macros indirectly or can be hidden in the common compiler settings. with your bash profile you can overrule the defaults. ask someone with administrator rights what you have to do such that the newer compiler was used.
Sara
ASKER
I removed bash profile files for old and new compiler from my computer. My code(program) still builds with old compiler.
WinSCP or Linux OS seems to have bash profile information? How to remove bash profile information from WinSCP so bash profile file will be read before build starts.
WinSCP or Linux OS seems to have bash profile information? How to remove bash profile information from WinSCP so bash profile file will be read before build starts.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
probably best is to make start script per build, one for each compiler much like vcvarsall.bat