nicolas06
(Nicolas)
February 22, 2021, 5:22pm
2
Hi Ayyappa,
You need to extend Gradle and add a new toolchain to support the compilation of Pro C files. It is possible but you need some good knowledge of Gradle. Have a look here:
I’m using a new native plugins (cpp-library, cpp-application) without old software model.
https://docs.gradle.org/current/userguide/building_cpp_projects.html
My question is: how can I customize gcc compiler (from compat-gcc-44-c++ package) executable for them???
I don’t see any sample of customizing toolChain object - just selection other options based on the value of toolChain
UPDATE: managed to find this sample, but it does not work as exected:
application {
toolChains {
wit…
and here:
It seems the cpp-library thinks that the only processor architecture in the world is Intel. How do we extend this to cross-compile for Arm? With the old cpp plugin I had something like this to add a tool-chain for Arm:
toolChains {
gcc(Gcc) {
target('x64') {
compilerProbeArgs '-m64'
}
target('x86') {
compilerProbeArgs '-m32', '-march=i686'
}
}
clang(Clang) {
target('x64') {
compilerProbeArgs '-m64'
…
It may help.