R16 SDK with XCode 5.1 [SOLVED]
-
On 17/08/2015 at 15:55, xxxxxxxx wrote:
User Information:
Cinema 4D Version:
Platform:
Language(s) :---------
Hi! I'm getting compiler errors when compiling the R16 SDK with XCode. Any idea where they could
originate from? Is XCode 5.1 incompatible with the R16 SDK?Edit : I've put the errors on pastebin as the formatting was kind of messed up after pasting here.
-
On 18/08/2015 at 08:05, xxxxxxxx wrote:
Hi Niklas,
in general it should work. I just tested the cinema4dsdk examples of R16 in my Xcode 5.1.1 and it worked as it should. Xcode 5.0.2 should be enough to compile R16 SDK.
It looks as if declval is missing in your std library. Could it be, that something messed up your toolchain? Or that the project file got changed? Which compiler is set in your project? -
On 18/08/2015 at 08:59, xxxxxxxx wrote:
Originally posted by xxxxxxxx
<ADDRESS>
User Information:
Cinema 4D Version:
Platform:
Language(s) :---------
</ADDRESS>
Hi! I'm getting compiler errors when compiling the R16 SDK with XCode. Any idea where they could
originate from? Is XCode 5.1 incompatible with the R16 SDK?
Edit : I've put the errors on pastebin as the formatting was kind of messed up after pasting here.
http://pastebin.com/Nk2wL9QWAre you using the supplied Xcode project or is this your own build chain? (I'm using 5.02 & 5.1.1 on OS X 10.8.5 without any problems).
Best regards,
Wilfried
-
On 01/09/2015 at 02:15, xxxxxxxx wrote:
Hi Wilfried, Andreas,
I had some permissions problems with XCode before but it works now and I can compile the R16 SDK
using XCode. But you're guts are right, I'm using my own build chain for which it does not work.
I'd greatly appreciate hints (or even solutions ;-), but I can understand if you can not give support
for custom build chains.I copied the command to build an object file of the R16 SDK almost entirely from the XCode build log,
but I keep getting these errors.# Module maxon.c4d # Target Objects rule maxon.c4d.Objects command = clang++ -c -arch x86_64 -fmessage-length=0 -Wno-trigraphs -fno-rtti -fpascal-strings -Wno-missing-field-initializers -Wno-missing-prototypes -Wreturn-type -Wno-non-virtual-dtor -Wno-exit-time-destructors -Wformat -Wmissing-braces -Wparentheses -Wno-switch -Wunused-function -Wunused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wno-empty-body -Wuninitialized -Wunknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wconstant-conversion -Wint-conversion -Wno-shorten-64-to-32 -Wenum-conversion -Wno-newline-eof -Wno-c++11-extensions -fasm-blocks -fstrict-aliasing -Wdeprecated-declarations -Wno-invalid-offsetof -msse3 -fvisibility=hidden -fvisibility-inlines-hidden -Wno-sign-conversion -Wno-logical-op-parentheses -funsafe-math-optimizations -ftrapping-math -c -std=c++11 -fno-exceptions -stdlib=libstdc++ -O3 -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_customgui' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_gv' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_libs' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/datastructures' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/memory' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/utilities' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_preview' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_scaling' -I '/Users/niklas/Applications/Cinema 4D R16/resource/res/description' -D MAC -D C4D_COCOA -D __clang__ -D __LP64__ -D MAXON_API -D MAXON_TARGET_OSX $in -o $out
Output is
[maxon.c4d|L80 ]: SDK Version: R16, Target: x86_64 craftr: exporting to "build.ninja"... [1/140] clang++ -c -arch x86_64 -fmessage-length...arwin-x86_64-release/obj/c4d_gv/c4d_graphview.o" FAILED: clang++ -c -arch x86_64 -fmessage-length=0 -Wno-trigraphs -fno-rtti -fpascal-strings -Wno-missing-field-initializers -Wno-missing-prototypes -Wreturn-type -Wno-non-virtual-dtor -Wno-exit-time-destructors -Wformat -Wmissing-braces -Wparentheses -Wno-switch -Wunused-function -Wunused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wno-empty-body -Wuninitialized -Wunknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wconstant-conversion -Wint-conversion -Wno-shorten-64-to-32 -Wenum-conversion -Wno-newline-eof -Wno-c++11-extensions -fasm-blocks -fstrict-aliasing -Wdeprecated-declarations -Wno-invalid-offsetof -msse3 -fvisibility=hidden -fvisibility-inlines-hidden -Wno-sign-conversion -Wno-logical-op-parentheses -funsafe-math-optimizations -ftrapping-math -c -std=c++11 -fno-exceptions -stdlib=libstdc++ -O3 -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_customgui' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_gv' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_libs' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/datastructures' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/memory' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/utilities' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_preview' -I '/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_scaling' -I '/Users/niklas/Applications/Cinema 4D R16/resource/res/description' -D MAC -D C4D_COCOA -D __clang__ -D __LP64__ -D MAXON_API -D MAXON_TARGET_OSX "/Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_gv/c4d_graphview.cpp" -o "/Users/niklas/Applications/Cinema 4D R16/plugins/craftr-c4d/build/Darwin-x86_64-release/obj/c4d_gv/c4d_graphview.o" In file included from /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_gv/c4d_graphview.cpp:1: In file included from /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_gv/c4d_graphview.h:10: In file included from /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_general.h:80: In file included from /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_string.h:25: In file included from /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/operatingsystem.h:10: In file included from /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/ge_math.h:10: In file included from /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/ge_sys_math.h:14: /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/general.h:198:37: error: no member named 'declval' in namespace 'std' template <typename T> decltype(std::declval<T>().CopyFrom(std::declval<const T&>())) TestForCopyFromFunction(OverloadRank1); // template argument can only be deduced if T contains a CopyFrom() method ~~~~~^ /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/general.h:198:45: error: 'T' does not refer to a value template <typename T> decltype(std::declval<T>().CopyFrom(std::declval<const T&>())) TestForCopyFromFunction(OverloadRank1); // template argument can only be deduced if T contains a CopyFrom() method ^ /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/general.h:198:20: note: declared here template <typename T> decltype(std::declval<T>().CopyFrom(std::declval<const T&>())) TestForCopyFromFunction(OverloadRank1); // template argument can only be deduced if T contains a CopyFrom() method ^ /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/general.h:198:48: error: expected expression template <typename T> decltype(std::declval<T>().CopyFrom(std::declval<const T&>())) TestForCopyFromFunction(OverloadRank1); // template argument can only be deduced if T contains a CopyFrom() method ^ /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/general.h:198:64: error: no member named 'declval' in namespace 'std' template <typename T> decltype(std::declval<T>().CopyFrom(std::declval<const T&>())) TestForCopyFromFunction(OverloadRank1); // template argument can only be deduced if T contains a CopyFrom() method ~~~~~^ /Users/niklas/Applications/Cinema 4D R16/frameworks/cinema.framework/source/c4d_misc/general.h:198:72: error: expected expression template <typename T> decltype(std::declval<T>().CopyFrom(std::declval<const T&>())) TestForCopyFromFunction(OverloadRank1); // template argument can only be deduced if T contains a CopyFrom() method ^ 5 errors generated. ninja: build stopped: subcommand failed.
Thanks,
Niklas -
On 01/09/2015 at 02:27, xxxxxxxx wrote:
Originally posted by xxxxxxxx
Hi Wilfried, Andreas,
I had some permissions problems with XCode before but it works now and I can compile the R16 SDK
using XCode. But you're guts are right, I'm using my own build chain for which it does not work.
I'd greatly appreciate hints (or even solutions ;-), [...]
NiklasYou're using the outdated GNU C++ standard lib
-stdlib=libstdc++Use the LLVM libc++ instead. For all other options compare our compiler command lines in the Xcode output with your settings.
Best regards,
Wilfried
-
On 01/09/2015 at 02:29, xxxxxxxx wrote:
Thanks a lot Wilfried! That was a mistake while transferring the arguments. Now it works!
Actually that was exactly what I did just the second before you posted and that was the only difference
in the commands.