Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build error on iOS #22

Closed
rinopazzo opened this issue Nov 25, 2015 · 4 comments
Closed

Build error on iOS #22

rinopazzo opened this issue Nov 25, 2015 · 4 comments
Labels

Comments

@rinopazzo
Copy link

I have the flowing errors:

The following build commands failed:
    CompileC /Users/rinopazzo/buildcasablanca/casablanca/Build_iOS/build.ioldcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:2927:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isUint64 && IntTraits<U>::isUint64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:2936:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isUint64 && IntTraits<U>::isUint64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:2950:9: errs/build.arm/src/casablanca.build/Release-iphoneos/cpprest.build/Objects-normal/armv7/http_client_msg.o src/http/clor: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isUint64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:2958:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isUint64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:2972:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<U>::isUint64 );
        ^
/Users/rinoient/http_client_msg.cpp normal armv7 c++ com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)
pazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:2988:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<U>::isUint64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3004:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isUint64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3012:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isUint64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3025:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isUint64 && IntTraits<U>::isInt64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3034:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isUint64 && IntTraits<U>::isInt64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3048:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<U>::isInt64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3064:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<U>::isInt64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3080:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isInt64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3088:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isInt64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3100:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isInt64 && IntTraits<U>::isInt64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3109:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isInt64 && IntTraits<U>::isInt64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3123:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isInt64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3131:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<T>::isInt64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:3144:9: error: unused typedef '__C_ASSERT__' [-Werror,-Wunused-local-typedef]
        C_ASSERT( IntTraits<U>::isUint64 );
        ^
/Users/rinopazzo/buildcasablanca/casablanca/Release/include/cpprest/details/SafeInt3.hpp:153:34: note: expanded from macro 'C_ASSERT'
#define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1]
                                 ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.

make[2]: *** [CMakeFiles/arm] Error 65
make[1]: *** [CMakeFiles/arm.dir/all] Error 2
make: *** [all] Error 2

@rinopazzo
Copy link
Author

[SOLVED] It works, I solved adding "-Wno-error" and "-Wno-unused-local-typedefs" into https://github.com/Microsoft/cpprestsdk/blob/master/Release/CMakeLists.txt#L137 . Thanks!

@ras0219-msft
Copy link
Contributor

Thanks for sharing your fix 👍

@oldoak
Copy link

oldoak commented Dec 9, 2015

Thanks! I was struggling with this build.

@brunodeandrade
Copy link

Thank you! It helped me a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants