Compile+Build with external gcc
-
wrote on 22 Oct 2012, 19:41 last edited by
Hello,
I want to build a QT console application with external gcc toolchain (created with the crosstool-ng project)
and not with the default gcc installed on my Centos 5.8Is it possible ?
I need external gcc because my application will run under kernel 2.6.27.35
The toolchain was build using this kernel headers.Centos 5.8 runs with a patched 2.6.18 kernel.
Thanks,
Zvika -
It is. If you are using Qt Creator, use Tools and Kits to set up your toolchain. If you are using just qmake, you need to adjust one of the mkspecs (or create your own) from <install dir>/mkspecs so that it uses the compiler you want, and then run your project with:
@
qmake -spec name-of-your-makespec
make
@ -
wrote on 23 Oct 2012, 08:53 last edited by
You will need to edit the mkspec when using qmake (provided your GCC is not called gcc/g++), even if you point creator to the right tool chain: Unfortunately we can not set the compiler name that qmake will use:-/ That needs to be changed in the mkspec.
The path to the compiler will be set by creator.
-
wrote on 23 Oct 2012, 20:40 last edited by
Dear Members,
After downloading and extracting qt-everywhere-opensource-src-4.8.3.tar.gz should I compile it using the external gcc ?
What is the role of " -embedded " in the .configure phase ?
Thanks,
Zvika -
wrote on 23 Oct 2012, 20:49 last edited by
What is this "external gcc" you are talking about? I am not aware of any internal one, so I keep wondering:-)
-
wrote on 24 Oct 2012, 03:34 last edited by
Hello,
The "external gcc" is a gcc toolchain built with crosstool-ng project (1.5.2).
This toolchain was used to build the kernel (2.6.27.35), device driver and application.I think all libraries I'm using (e.g QT) should also built with this toolchain.
Am I right ?Thanks,
Zvika
1/6