Libsupcxx: Difference between revisions
Jump to navigation
Jump to search
[unchecked revision] | [unchecked revision] |
Content deleted Content added
m Unrated tutorial |
m /usr/cross -> /usr/local/cross for FHS compatibility |
||
Line 8: | Line 8: | ||
Enter the gcc source directory, run |
Enter the gcc source directory, run |
||
./configure --target=i586-elf --prefix=/usr/cross --enable-languages=c,c++ \ |
./configure --target=i586-elf --prefix=/usr/local/cross --enable-languages=c,c++ \ |
||
--without-headers --disable-nls |
--without-headers --disable-nls |
||
cd libstdc++-v3 |
cd libstdc++-v3 |
||
Line 29: | Line 29: | ||
=== Configure and make libsupc++ === |
=== Configure and make libsupc++ === |
||
CPP=i586-elf-cpp ./configure --host=i586-elf --prefix=/usr/cross --disable-hosted-libstdcxx \ |
CPP=i586-elf-cpp ./configure --host=i586-elf --prefix=/usr/local/cross --disable-hosted-libstdcxx \ |
||
--disable-nls |
--disable-nls |
||
cd include |
cd include |
||
Line 39: | Line 39: | ||
=== Usage === |
=== Usage === |
||
Libsupc++ should now be installed into /usr/cross/lib. To use it, you will need to add |
Libsupc++ should now be installed into /usr/local/cross/lib. To use it, you will need to add |
||
-L/usr/cross/lib -lsupc++ |
-L/usr/local/cross/lib -lsupc++ |
||
to your linker command line. |
to your linker command line. |
||
=== Additional requirements === |
=== Additional requirements === |
||
Libsupc++ also requires that libgcc.a be included in your link as well. This is usually found (if you followed the cross compiler directions) in /usr/cross/lib/gcc/i586-elf/<gcc version>. Finally, it has a number of dependencies which your kernel must provide, including (but not limited to) malloc, free, abort and strlen. |
Libsupc++ also requires that libgcc.a be included in your link as well. This is usually found (if you followed the cross compiler directions) in /usr/local/cross/lib/gcc/i586-elf/<gcc version>. Finally, it has a number of dependencies which your kernel must provide, including (but not limited to) malloc, free, abort and strlen. |
||
=== Tested on === |
=== Tested on === |