arm-linux-androideabi-g++.exe and others are inDid you name the compiler's executables names like that?
Yes, compiler executables have such names. CodeSourcery Tollset compiler has name "arm-none-linux-gnueabi-g++.exe", but it works fine.arm-linux-androideabi-g++.exe and others are inDid you name the compiler's executables names like that?
So either the names of your tools are wrong, or the path's.
Error: the tool chain [compiler|linker|other] command [was not set|'[command name or command line]' was not found], please check your tool chain settings in Settings -> Compiler
We need to do something about that error message.Although we did quite some time in the past already, but: Yes (even before he release). Will you take the action?
We need to do something about that error message.Although we did quite some time in the past already, but: Yes (even before he release). Will you take the action?
Do you have a valid executable in the C-compiler field ?Yes, all fields are properly filled
Yes, all fields are properly filledYou can use the cb_share_config tool, export the compiler settings in question and attach it to a post here, besides you PATH environment variable, and again the exact path where you installed your compiler into.
We need to do something about that error message.It's a good idea.
Next, The executable are under bin subdirectory of taken directory, but I can't understand, is path incorrect or something wrong then compiler tryed to run.
You can use the cb_share_config tool, export the compiler settings in question and attach it to a post here, besides you PATH environment variable, and again the exact path where you installed your compiler into.NDK root: D:\android-ndk-r8b
BTW: I didn't even know there is a GCC for android... interesting... :-)Android Native Development Kit - NDK
First, it is not quite how works the "Autodetect" button - it simply reports that nothing is found and fills "Compiler install dir" with "C:\Program Files (x86)\GNUARM" value.This is by design. The folder is the default folder, where the compiler usually is installed, if you run its installer.
Next, The executable are under bin subdirectory of taken directory, but I can't understand, is path incorrect or something wrong then compiler tryed to run.Well you can - what I told you is true: If you see this message, CodeBlocks cannot find the compiler computed by [list of path's] + compiler executable.
Third, what is strange restriction when binaries must be placed under "bin" subdirectory? I think, much better to point exact to directory which contains compiler executables.Again, this is by design. Most compilers are setup in a way that they have a root folder, which has at least the sub-folders "bin" for the tool chain executables, an"include" folder for its includes and a "lib" folder for libraries. So having to setup the root path is just convenient to find all the rest. Otherwise it will become so complicated that out forum will be flooded with messages "I don't get the compiler to run" - trust me.
Fourth, near all fields, near [...] button will be cool if one more button be placed, [AutoLocate] - pressing on it C::B looks for files in "compiler/install/dir/bin" with mack "*gcc", "*g++", "*ar", "*gdb" etc.Nope. We also support compilers like MSVC where you don't have such executables and even non c/c++ compiler (take Fortran, for example). Also, we support compilers that do not have such a standard folder structure. So your suggestion will break all these cases. the way it is now works for all of them and more.[/list]
@op: did you install the NDK while C::B is open? Sometimes I have found you need to close and reopen C::B for the environment to pick things up correctly. (This one is probably a stretch)
[...]Your compiler setup is wrong.
Related: because the IsValid() check returns false, we get this "invalid" compiler message instead of attempting to run the toolchain command. It's bizarre that the check is only based on the C toolchain command and apparently not anything else.Well the reason for this is that i.e. for MSVC you might only have a C compiler and nothing else. So we don't want to have it overdone. the only exception I can think of is to check for if either the C or the C++ executable is present. But the rest we should leave. Remember that there might even be no "make", no "linker", no "resource compiler".
Next, The executable are under bin subdirectory of taken directory, but I can't understand, is path incorrect or something wrong then compiler tryed to run.Well you can - what I told you is true: If you see this message, CodeBlocks cannot find the compiler computed by [list of path's] + compiler executable.
Fourth, near all fields, near [...] button will be cool if one more button be placed, [AutoLocate] - pressing on it C::B looks for files in "compiler/install/dir/bin" with mack "*gcc", "*g++", "*ar", "*gdb" etc.Nope. We also support compilers like MSVC where you don't have such executables and even non c/c++ compiler (take Fortran, for example). Also, we support compilers that do not have such a standard folder structure. So your suggestion will break all these cases. the way it is now works for all of them and more.[/list]
I think IsValid() should return an enumeration that helps to identify what the error is. Or (maybe a bit ugly) a wxString with the exact error description and wxEmptyString if all is OK.
[...]Your compiler setup is wrong.
Accoridn to your config, you setup a wrong C toolchain executable. If your compiler does not have a GCC, setup the G++ here, too.
I just successfully configured NDK on my PC - so it definitely works with the right setup.
But compiler exact under that path - I try to copy path, paste it to console, type "\bin\", copy and paste execuatable name, press enter - compiler launches.No. You setup "arm-linux-androideabi-gcc.exe" as C toolchain application. This file does not exist. Therefore, your compiler setup is wrong. Thats what the error message tells you.
My configuration is Win7 x64; C::B 8.05 with MinGW, 32 bit; 32bit NDK.Oh dear - you mean 08/02? You really try to use an IDE that is so old that android did not even exist at that time?! :o
But compiler exact under that path - I try to copy path, paste it to console, type "\bin\", copy and paste execuatable name, press enter - compiler launches.No. You setup "arm-linux-androideabi-gcc.exe" as C toolchain application. This file does not exist. Therefore, your compiler setup is wrong. Thats what the error message tells you.
(...or maybe I misunderstood. Is it working now?!)
This file exist in my NDK.Ok - but what shall I say? Even if I setup with this executable, it works for me. Maybe you should try a nightly (or 12/11-RC1).
Yes. I use only official releases, not nightly builds or release candidates. And, I'm lazy for installing MinGW separately, so I'm waiting for C::B 12.11.My configuration is Win7 x64; C::B 8.05 with MinGW, 32 bit; 32bit NDK.Oh dear - you mean 08/02? You really try to use an IDE that is so old that android did not even exist at that time?! :o
...btw: You are not down the road once you made this work I can tell you - you'll need to do a lot low-level stuff in addition so it actually not only compiles, but also links.
My suggestion: Try at the command line first with the "hello world" project. Because you'll definitely need the platform flags, #defines and a lot more to setup your compiler correctly. Its easy if you see the command line one time so you are not stepping in the dark (...at least I found no good tutorial about it).
Configuring compilers flags for android platfrom seems not hard for me - I can grab them from eclipse build logsCan you provide me with one here, so I can try, too?
Currently I'm really thinking about the work from the command line, but using C :: B would be much more convenient.Sure, in the end it will be way more convenient - but I said that to get the command line - if you have the Eclipse way - do it like this.
UPD Setting "C compiler" same as "C++ compiler" to g++ not solve the problem.Well that is weird. What you can try now: Use the EnvVar plugin and clean up your PATH environment variable. You have plenty of compilers in the path, so this may interfere.
set CB_ROOT=[...DO IT!...]
set WIN_ROOT=[...DO IT!...]
SET PATH=%WIN_ROOT%;%WIN_ROOT\sytem32;%CB_ROOT%
"%CB_ROOT%\codeblocks.exe" %*
Configuring compilers flags for android platfrom seems not hard for me - I can grab them from eclipse build logsCan you provide me with one here, so I can try, too?
**** Build of configuration Default for project GorgeousKarnaugh ****
bash D:\android-ndk-r8b\\ndk-build V=1
Invalid attribute name:
package
rm -f ./libs/armeabi/lib*.so ./libs/armeabi-v7a/lib*.so ./libs/mips/lib*.so ./libs/x86/lib*.so
rm -f ./libs/armeabi/gdbserver ./libs/armeabi-v7a/gdbserver ./libs/mips/gdbserver ./libs/x86/gdbserver
rm -f ./libs/armeabi/gdb.setup ./libs/armeabi-v7a/gdb.setup ./libs/mips/gdb.setup ./libs/x86/gdb.setup
Compile++ arm : GorgeousKarnaugh <= GorgeousKarnaugh.cpp
/d/android-ndk-r8b/toolchains/arm-linux-androideabi-4.6/prebuilt/windows/bin/arm-linux-androideabi-g++ -MMD -MP -MF ./obj/local/armeabi/objs/GorgeousKarnaugh/GorgeousKarnaugh.o.d.org -fpic -ffunction-sections -funwind-tables -fstack-protector -D__ARM_ARCH_5__ -D__ARM_ARCH_5T__ -D__ARM_ARCH_5E__ -D__ARM_ARCH_5TE__ -march=armv5te -mtune=xscale -msoft-float -fno-exceptions -fno-rtti -O2 -fomit-frame-pointer -fstrict-aliasing -funswitch-loops -finline-limit=300 -I/d/agg-2.5/include -I/f/work/carno/include -I/d/android-ndk-r8b/sources/cxx-stl/gnu-libstdc++/4.6/include -I/d/android-ndk-r8b/sources/cxx-stl/gnu-libstdc++/4.6/libs/armeabi/include -I/d/android-ndk-r8b/sources/cxx-stl/system/include -Ijni -DANDROID -Werror -Wa,--noexecstack -O2 -DNDEBUG -g -I/d/android-ndk-r8b/platforms/android-14/arch-arm/usr/include -c jni/GorgeousKarnaugh.cpp -o ./obj/local/armeabi/objs/GorgeousKarnaugh/GorgeousKarnaugh.o && ./obj/convert-dependencies.sh ./obj/local/armeabi/objs/GorgeousKarnaugh/GorgeousKarnaugh.o.d
In file included from jni/GorgeousKarnaugh.cpp:2:0:
d:/android-ndk-r8b/platforms/android-14/arch-arm/usr/include/jni.h:592:13: note: the mangling of 'va_list' has changed in GCC 4.4
Compile arm : GorgeousKarnaugh <= gkcstuff.c
/d/android-ndk-r8b/toolchains/arm-linux-androideabi-4.6/prebuilt/windows/bin/arm-linux-androideabi-gcc -MMD -MP -MF ./obj/local/armeabi/objs/GorgeousKarnaugh/gkcstuff.o.d.org -fpic -ffunction-sections -funwind-tables -fstack-protector -D__ARM_ARCH_5__ -D__ARM_ARCH_5T__ -D__ARM_ARCH_5E__ -D__ARM_ARCH_5TE__ -march=armv5te -mtune=xscale -msoft-float -O2 -fomit-frame-pointer -fstrict-aliasing -funswitch-loops -finline-limit=300 -I/d/agg-2.5/include -I/f/work/carno/include -I/d/android-ndk-r8b/sources/cxx-stl/gnu-libstdc++/4.6/include -I/d/android-ndk-r8b/sources/cxx-stl/gnu-libstdc++/4.6/libs/armeabi/include -I/d/android-ndk-r8b/sources/cxx-stl/system/include -Ijni -DANDROID -Werror -Wa,--noexecstack -O2 -DNDEBUG -g -I/d/android-ndk-r8b/platforms/android-14/arch-arm/usr/include -c jni/gkcstuff.c -o ./obj/local/armeabi/objs/GorgeousKarnaugh/gkcstuff.o && ./obj/convert-dependencies.sh ./obj/local/armeabi/objs/GorgeousKarnaugh/gkcstuff.o.d
SharedLibrary : libGorgeousKarnaugh.so
/d/android-ndk-r8b/toolchains/arm-linux-androideabi-4.6/prebuilt/windows/bin/
arm-linux-androideabi-g++ -Wl,-soname,libGorgeousKarnaugh.so
-shared --sysroot=/d/android-ndk-r8b/platforms/android-14/arch-arm
./obj/local/armeabi/objs/GorgeousKarnaugh/GorgeousKarnaugh.o ./obj/local/armeabi/objs/GorgeousKarnaugh/gkcstuff.o ./obj/local/armeabi/libstdc++.a
-Wl,--no-undefined -Wl,-z,noexecstack -Wl,-z,relro -Wl,-z,now
-L/d/android-ndk-r8b/platforms/android-14/arch-arm/usr/lib
-lstdc++ -lc -lm -o obj/local/armeabi/libGorgeousKarnaugh.so
Install : libGorgeousKarnaugh.so => libs/armeabi/libGorgeousKarnaugh.so
mkdir -p ./libs/armeabi
install -p ./obj/local/armeabi/libGorgeousKarnaugh.so ./libs/armeabi/libGorgeousKarnaugh.so
/d/android-ndk-r8b/toolchains/arm-linux-androideabi-4.6/prebuilt/windows/bin/arm-linux-androideabi-strip --strip-unneeded ./libs/armeabi/libGorgeousKarnaugh.so
UPD Setting "C compiler" same as "C++ compiler" to g++ not solve the problem.Well that is weird. What you can try now: Use the EnvVar plugin and clean up your PATH environment variable. You have plenty of compilers in the path, so this may interfere.
Alternatively, just create yourself a batch file like this:
set CB_ROOT=C:\Program Files (x86)\CodeBlocks
set WIN_ROOT=C:\Windows
SET PATH=%WIN_ROOT%;%WIN_ROOT\system32;%CB_ROOT%
"%CB_ROOT%\codeblocks.exe" %*
Didnt we once have issues with mingw installed on d drive and C::B on c drive on win 7? Did you try putting everything on one drive?
Didnt we once have issues with mingw installed on d drive and C::B on c drive on win 7? Did you try putting everything on one drive?
I have no problems with MinGW in C::B, problem is with NDK ;)Well the only difference between me (where it works) and you is that am using a recent build. So let me encourage you again to try 12/11-RC1. Since 10/05 we did change the way how compiler path's are handled.
I have no problems with MinGW in C::B, problem is with NDK ;)Well the only difference between me (where it works) and you is that am using a recent build. So let me encourage you again to try 12/11-RC1. Since 10/05 we did change the way how compiler path's are handled.
Ok. Can you give the link to download this version of C::B? I can't find it on C::B siteUse BerliOS here:
Ok. Can you give the link to download this version of C::B? I can't find it on C::B siteUse BerliOS here:
http://developer.berlios.de/project/showfiles.php?group_id=5358
You SHOULD use an empty folder to do the installation.
DO NOT INSTALL TO THE SAME FOLDER UNLESS CONTENTS WAS ALL DELETED.
Tim S.
Has this issue been resolved?
I'd like to do the same - use C::B for Android NDK compiler.
Thanks,
Tamara
-----You SHOULD use an empty folder to do the installation.
DO NOT INSTALL TO THE SAME FOLDER UNLESS CONTENTS WAS ALL DELETED.
Tim S.
Oh, I just want to know if I anyone managed to use C::B with NDK. It seems that one user was trying and gave up? I think I know what I am doing and I am not afraid of compiling C::B from source, but would prefer to avoid large amounts of work.
Thanks,
Tamara
An example:
In the 'Compiler's installation directory' put:
E:\android-ndk-toolchain\arm-linux-androideabi (*)
And in the 'Additional Paths' put:
E:\android-ndk-toolchain\bin
* note: This is in fact not the correct location but one that Code::Blocks accepts.
An example:
In the 'Compiler's installation directory' put:
E:\android-ndk-toolchain\arm-linux-androideabi (*)
And in the 'Additional Paths' put:
E:\android-ndk-toolchain\bin
* note: This is in fact not the correct location but one that Code::Blocks accepts.
What did you try as the correct value in 'Compiler's installation directory'?
Tim S.