signalwire / libstirshaken

C library implementing STIR-shaken STI-SP AS/VS, STI-CA
MIT License
31 stars 23 forks source link

Build Error #126

Open sharif779 opened 1 year ago

sharif779 commented 1 year ago

System =CentOS 7 ./bootstrap.sh=Successfull ./configure=successfull make=getting following error

make
  CC       src/stir_shaken.lo
In file included from src/stir_shaken.c:1:0:
include/stir_shaken.h:17:1: error: C++ style comments are not allowed in ISO C90 [-Werror]
 // For JSON Web Token, used to implement PASSporT
 ^
include/stir_shaken.h:17:1: error: (this will be reported only once per input file) [-Werror]
In file included from src/stir_shaken.c:1:0:
include/stir_shaken.h:83:35: error: comma at end of enumerator list [-Werror=pedantic]
  STIR_SHAKEN_CERT_TYPE_SELF_SIGNED,
                                   ^
include/stir_shaken.h:95:32: error: comma at end of enumerator list [-Werror=pedantic]
  STIR_SHAKEN_STATUS_NOT_HANDLED,
                                ^
include/stir_shaken.h:101:49: error: comma at end of enumerator list [-Werror=pedantic]
  STIR_SHAKEN_VERIFICATION_STATUS_BAD_CERTIFICATE,
                                                 ^
In file included from src/stir_shaken.c:1:0:
include/stir_shaken.h:738:29: error: comma at end of enumerator list [-Werror=pedantic]
  STIR_SHAKEN_ERROR_UNKNOWN_2,
                             ^
include/stir_shaken.h:752:48: error: comma at end of enumerator list [-Werror=pedantic]
  STIR_SHAKEN_CALLBACK_ACTION_CERT_FETCH_ENQUIRY,
                                                ^
include/stir_shaken.h:1069:128: error: ISO C90 does not support 'long long' [-Werror=long-long]
 stir_shaken_status_t stir_shaken_x509_req_add_tnauthlist_extension_spc(stir_shaken_context_t *ss, X509_REQ *req, unsigned long long int spc);
                                                                                                                                ^
include/stir_shaken.h:1268:164: error: ISO C90 does not support 'long long' [-Werror=long-long]
 stir_shaken_status_t stir_shaken_acme_api_uri_to_spc(stir_shaken_context_t *ss, const char *uri_request, const char *api_url, char *buf, int buflen, unsigned long long int *sp_code, int *uri_has_secret, unsigned long long *secret);
                                                                                                                                                                    ^
include/stir_shaken.h:1268:218: error: ISO C90 does not support 'long long' [-Werror=long-long]
 stir_shaken_status_t stir_shaken_acme_api_uri_to_spc(stir_shaken_context_t *ss, const char *uri_request, const char *api_url, char *buf, int buflen, unsigned long long int *sp_code, int *uri_has_secret, unsigned long long *secret);
                                                                                                                                                                                                                          ^
include/stir_shaken.h:1409:30: error: anonymous variadic macros were introduced in C99 [-Werror=variadic-macros]
 #define fprintif(level, fmt, ...) \
                              ^
include/stir_shaken.h:1474:16: error: ISO C90 does not support 'long long' [-Werror=long-long]
  unsigned long long int spc;
                ^
include/stir_shaken.h:1475:16: error: ISO C90 does not support 'long long' [-Werror=long-long]
  unsigned long long authz_secret;
                ^
include/stir_shaken.h:1532:93: error: ISO C90 does not support 'long long' [-Werror=long-long]
 stir_shaken_status_t ca_verify_spc(stir_shaken_context_t *ss, jwt_t *spc_jwt, unsigned long long int spc);
                                                                                             ^
src/stir_shaken.c: In function 'stir_shaken_init_basic_and_ssl':
src/stir_shaken.c:58:3: error: C++ style comments are not allowed in ISO C90 [-Werror]
   // TODO basic deinit
   ^
src/stir_shaken.c:58:3: error: (this will be reported only once per input file) [-Werror]
src/stir_shaken.c: At top level:
cc1: error: unrecognized command line option "-Wno-gnu-zero-variadic-macro-arguments" [-Werror]
cc1: all warnings being treated as errors
sonipresent commented 1 year ago

same for me any one? root@test-Latitude-5490:/usr/src/libstirshaken# make -j nproc CC src/stir_shaken_service.lo CC src/stir_shaken_ssl.lo CC src/stir_shaken_acme.lo src/stir_shaken_ssl.c: In function ‘stir_shaken_generate_keys’: src/stir_shaken_ssl.c:2292:79: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_HIGH, "Got new private/public EC key pair\n"); ^ src/stir_shaken_service.c: In function ‘stir_shaken_curl_header_callback’: src/stir_shaken_service.c:42:95: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] L_HIGH, "STIR-Shaken: CURL: Received empty header... skipping\n"); ^ src/stir_shaken_acme.c: In function ‘stir_shaken_acme_poll’: src/stir_shaken_acme.c:802:86: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "\t-> Got 'valid' polling status\n"); ^ src/stir_shaken_acme.c:809:95: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "\t-> Got 'failed' polling status\n"); ^ src/stir_shaken_acme.c:815:92: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "\t-> Got malformed polling status\n"); ^ src/stir_shaken_acme.c:822:109: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "\t-> Got 'pending' polling status, continue polling...\n"); ^ src/stir_shaken_acme.c: In function ‘stir_shaken_acme_perform_authorization’: src/stir_shaken_acme.c:907:87: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "-> Processing authorization challenge...\n"); ^ src/stir_shaken_acme.c:913:77: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "-> Authorization completed\n"); ^ src/stir_shaken_acme.c:930:80: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "\t-> Authorization is pending\n"); ^ src/stir_shaken_acme.c:964:101: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "\t-> Requesting authorization challenge details...\n"); ^ src/stir_shaken_acme.c:990:116: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "\t-> Sending a response to authorization challenge details...\n"); ^ src/stir_shaken_acme.c:1002:70: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "\t-> Polling...\n"); ^ src/stir_shaken_acme.c:1011:79: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_MEDIUM, "\t-> Polling finished...\n"); ^ src/stir_shaken_service.c: In function ‘stir_shaken_vs_verify_stica’: src/stir_shaken_service.c:409:51: error: ISO C99 requires at least one argument for the "..." in a variadic macro [-Werror] fprintif(STIR_SHAKEN_LOGLEVEL_HIGH, "invalid\n"); ^ src/stir_shaken_acme.c: At top level: cc1: error: unrecognized command line option ‘-Wno-gnu-zero-variadic-macro-arguments’ [-Werror] cc1: all warnings being treated as errors src/stir_shaken_service.c: At top level: cc1: error: unrecognized command line option ‘-Wno-gnu-zero-variadic-macro-arguments’ [-Werror] cc1: all warnings being treated as errors Makefile:1288: recipe for target 'src/stir_shaken_acme.lo' failed make: [src/stir_shaken_acme.lo] Error 1 make: Waiting for unfinished jobs.... Makefile:1288: recipe for target 'src/stir_shaken_service.lo' failed make: [src/stir_shaken_service.lo] Error 1 src/stir_shaken_ssl.c: At top level: cc1: error: unrecognized command line option ‘-Wno-gnu-zero-variadic-macro-arguments’ [-Werror] cc1: all warnings being treated as errors Makefile:1288: recipe for target 'src/stir_shaken_ssl.lo' failed make: [src/stir_shaken_ssl.lo] Error 1