Embedded Arm Dev
Posted: Sun Mar 16, 2008 2:00 pm
Hi Eran,
I am now using Codelite for my embedded Arm development.
First I must say thank you for big time for Codelite.
I have been using Codewright for years for my embedded development projects but have been following the progress of Codelight for some time thinking how I could use it for cross compiling and development. A previous post with reference to "Premake" showed me how to achieve this with Codelite's "Custom Build" capability.
I have been developing an Embedded Linux project using a Technologic Systems TS-7260 Arm 920 SBC and needed the capability of being able to compile natively using the usual Linux Makefile and in addition be able to Cross compile from Windows using a WinXP Cygwin based cross compiler. This means that although I am running on WinXP makefiles have Linux line endings. Moreover because the compiler is cygwin based one needs to operate from a "Unix style environment". In this respect I much prefer the Msys environment to the Cygwin one.
These are the steps to make this happen on WinXP
1. Install a basic Cygwin environmet in c:\cygwin
2. Install MSYS in c:\msys-1011
3. Install Technological Systems Arm cross compiler in c:\cygwin\opt
4. Install Codelight i c:\msys-1011\local\share
5. Make a copy of c:\msys-1011\etc\profile and call it codelite-profile
6. Edit codelte-profile to have the following at the end
#Noel's Environment Variables
export PATH="/opt/crosstool/gcc-3.3.4-glibc-2.3.2/arm-unknown-linux-gnu/arm-unknown-linux-gnu/bin:$PATH"
cd "$HOME"
# launch codelite
codelite
7. Edit c:\msys-1011\etc\fstab and add line
c:/cygwin/opt /opt
8. Make a copy of c:\msys-1011\msys.bat and call it msys-codelite.bat
9. Edit msys-codelite.bat to do the following
copy c:\msys-1011\etc\codelite-profile to c:\msys-1011\etc\profile
10. Create a desktop icon to launch msys-codelite.bat
Codelite is now launched for our embedded environment.
We now create our embedded project whic will be located in a Linux NFS fileshare which is booted from the TS-7260 SBC.
This is a copy of Eran's response to a previous post on "premake"
1. Create new workspace (Workspace -> Create New Workspace)
2. Create a project (Right click on the workspace icon to the left -> New Project), the type of the project does not really
matter since u will be using your own makefile / tool, so the for the sake of the example simply choose 'executable'
3. Expand the workspace icon, and you will see the project icon (3 blue icons), right click on it and select 'Import files
from directory', select the root directory where your files are located and select OK
4. Once the import is done, (you can expand the tree to the left to see all your source files) right click on the project icon,
and select 'Settings...'
5. In the settings dialog, select 'Custom Build'. First, enable the custom build (Enable Custom build checkbox), now, fill in
the commands you need to run for 'clean' and 'build'.
And we are done. The above assumes that you already vave a makefile. If not it is possible to use premake to create one.
Many thanks Eran for maiking this magic possible. It works like a treat.
Next step is to have an error parser for compilers other that GCC.
Best regards,
Noel Diviney.
I am now using Codelite for my embedded Arm development.
First I must say thank you for big time for Codelite.
I have been using Codewright for years for my embedded development projects but have been following the progress of Codelight for some time thinking how I could use it for cross compiling and development. A previous post with reference to "Premake" showed me how to achieve this with Codelite's "Custom Build" capability.
I have been developing an Embedded Linux project using a Technologic Systems TS-7260 Arm 920 SBC and needed the capability of being able to compile natively using the usual Linux Makefile and in addition be able to Cross compile from Windows using a WinXP Cygwin based cross compiler. This means that although I am running on WinXP makefiles have Linux line endings. Moreover because the compiler is cygwin based one needs to operate from a "Unix style environment". In this respect I much prefer the Msys environment to the Cygwin one.
These are the steps to make this happen on WinXP
1. Install a basic Cygwin environmet in c:\cygwin
2. Install MSYS in c:\msys-1011
3. Install Technological Systems Arm cross compiler in c:\cygwin\opt
4. Install Codelight i c:\msys-1011\local\share
5. Make a copy of c:\msys-1011\etc\profile and call it codelite-profile
6. Edit codelte-profile to have the following at the end
#Noel's Environment Variables
export PATH="/opt/crosstool/gcc-3.3.4-glibc-2.3.2/arm-unknown-linux-gnu/arm-unknown-linux-gnu/bin:$PATH"
cd "$HOME"
# launch codelite
codelite
7. Edit c:\msys-1011\etc\fstab and add line
c:/cygwin/opt /opt
8. Make a copy of c:\msys-1011\msys.bat and call it msys-codelite.bat
9. Edit msys-codelite.bat to do the following
copy c:\msys-1011\etc\codelite-profile to c:\msys-1011\etc\profile
10. Create a desktop icon to launch msys-codelite.bat
Codelite is now launched for our embedded environment.
We now create our embedded project whic will be located in a Linux NFS fileshare which is booted from the TS-7260 SBC.
This is a copy of Eran's response to a previous post on "premake"
1. Create new workspace (Workspace -> Create New Workspace)
2. Create a project (Right click on the workspace icon to the left -> New Project), the type of the project does not really
matter since u will be using your own makefile / tool, so the for the sake of the example simply choose 'executable'
3. Expand the workspace icon, and you will see the project icon (3 blue icons), right click on it and select 'Import files
from directory', select the root directory where your files are located and select OK
4. Once the import is done, (you can expand the tree to the left to see all your source files) right click on the project icon,
and select 'Settings...'
5. In the settings dialog, select 'Custom Build'. First, enable the custom build (Enable Custom build checkbox), now, fill in
the commands you need to run for 'clean' and 'build'.
And we are done. The above assumes that you already vave a makefile. If not it is possible to use premake to create one.
Many thanks Eran for maiking this magic possible. It works like a treat.
Next step is to have an error parser for compilers other that GCC.
Best regards,
Noel Diviney.