[MacPorts] #63644: ruby @1.8.7-p374_13: error: implicit declaration of function 'X509_STORE_get_ex_data' is invalid in C99

MacPorts noreply at macports.org
Tue Oct 19 09:29:00 UTC 2021


#63644: ruby @1.8.7-p374_13: error: implicit declaration of function
'X509_STORE_get_ex_data' is invalid in C99
--------------------------+-----------------------------
  Reporter:  cooljeanius  |      Owner:  (none)
      Type:  defect       |     Status:  new
  Priority:  Normal       |  Milestone:
 Component:  ports        |    Version:  2.7.1
Resolution:               |   Keywords:  bigsur catalina
      Port:  ruby         |
--------------------------+-----------------------------

Comment (by cjones051073):

 Actually you might be right, mot build instantiations correctly respect
 the confirmation to use openssl10 by places the include directive for this
 first

 {{{
 /usr/bin/clang -pipe -I/opt/local/libexec/openssl10/include -Os
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk -arch
 x86_64  -fno-common -pipe -fno-common    -DRUBY_EXPORT -arch x86_64 -I.
 -I. -I/opt/local/libexec/openssl10/include -I/opt/local/include
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk
 -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE   -c numeric.c
 }}}

 but not all...


 {{{
 /usr/bin/clang -I. -I../.. -I../../. -I../.././ext/tk -I/opt/local/include
 -I/opt/local/include -DHAVE_RB_SAFE_LEVEL -DHAVE_RB_HASH_LOOKUP
 -DHAVE_RB_PROC_NEW -DHAVE_RB_OBJ_TAINT -DHAVE_ST_PTR -DHAVE_ST_LEN
 -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1
 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1
 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DNO_VALUES_H=1
 -DHAVE_SYS_PARAM_H=1 -DUSE_THREAD_ALLOC=1 -D_REENTRANT=1 -D_THREAD_SAFE=1
 -DHAVE_PTHREAD_ATTR_SETSTACKSIZE=1 -DHAVE_PTHREAD_ATFORK=1 -DTCL_THREADS=1
 -DTCL_CFGVAL_ENCODING=\"iso8859-1\" -DHAVE_ZLIB=1 -DMODULE_SCOPE=extern\
 __attribute__\(\(__visibility__\(\"hidden\"\)\)\) -DHAVE_HIDDEN=1
 -DMAC_OSX_TCL=1 -DHAVE_COREFOUNDATION=1 -DHAVE_CAST_TO_UNION=1
 -DTCL_SHLIB_EXT=\".dylib\" -DNDEBUG=1 -DTCL_CFG_OPTIMIZED=1
 -DTCL_TOMMATH=1 -DMP_PREC=4 -DTCL_WIDE_INT_TYPE=long\ long
 -DHAVE_STRUCT_STAT64=1 -DHAVE_GETCWD=1 -DHAVE_MKSTEMP=1 -DHAVE_OPENDIR=1
 -DHAVE_STRTOL=1 -DHAVE_WAITPID=1 -DHAVE_GETNAMEINFO=1 -DHAVE_GETADDRINFO=1
 -DHAVE_FREEADDRINFO=1 -DHAVE_GAI_STRERROR=1 -DHAVE_STRUCT_ADDRINFO=1
 -DHAVE_STRUCT_IN6_ADDR=1 -DHAVE_STRUCT_SOCKADDR_IN6=1
 -DHAVE_STRUCT_SOCKADDR_STORAGE=1 -DHAVE_GETPWUID_R_5=1 -DHAVE_GETPWUID_R=1
 -DHAVE_GETPWNAM_R_5=1 -DHAVE_GETPWNAM_R=1 -DHAVE_GETGRGID_R_5=1
 -DHAVE_GETGRGID_R=1 -DHAVE_GETGRNAM_R_5=1 -DHAVE_GETGRNAM_R=1
 -DHAVE_MTSAFE_GETHOSTBYNAME=1 -DHAVE_MTSAFE_GETHOSTBYADDR=1
 -DHAVE_TERMIOS_H=1 -DHAVE_SYS_IOCTL_H=1 -DHAVE_SYS_TIME_H=1
 -DTIME_WITH_SYS_TIME=1 -DHAVE_GMTIME_R=1 -DHAVE_LOCALTIME_R=1
 -DHAVE_MKTIME=1 -DHAVE_TM_GMTOFF=1 -DHAVE_TIMEZONE_VAR=1
 -DHAVE_STRUCT_STAT_ST_BLOCKS=1 -DHAVE_STRUCT_STAT_ST_BLKSIZE=1
 -DHAVE_BLKCNT_T=1 -DHAVE_INTPTR_T=1 -DHAVE_UINTPTR_T=1
 -DHAVE_SIGNED_CHAR=1 -DHAVE_LANGINFO=1 -DHAVE_CHFLAGS=1 -DHAVE_MKSTEMPS=1
 -DHAVE_GETATTRLIST=1 -DHAVE_COPYFILE_H=1 -DHAVE_COPYFILE=1
 -DHAVE_LIBKERN_OSATOMIC_H=1 -DHAVE_OSSPINLOCKLOCK=1 -DUSE_VFORK=1
 -DTCL_DEFAULT_ENCODING=\"utf-8\" -DTCL_LOAD_FROM_MEMORY=1
 -DTCL_WIDE_CLICKS=1 -DHAVE_AVAILABILITYMACROS_H=1 -DHAVE_WEAK_IMPORT=1
 -D_DARWIN_C_SOURCE=1 -DHAVE_FTS=1 -DHAVE_SYS_FILIO_H=1 -DTCL_UNLOAD_DLLS=1
 -DHAVE_CPUID=1  -DTCL_CFG_DO64BIT=1 -DHAVE_PW_GECOS=1 -DHAVE_LIBXFT=1
 -DHAVE_XFT=1 -DHAVE_XKBKEYCODETOKEYSYM=1
 -DXKEYCODETOKEYSYM_IS_DEPRECATED=1 -DHAVE_XSS=1  -DRUBY_VERSION=\"1.8.7\"
 -DRUBY_RELEASE_DATE=\"2013-06-27\" -I/opt/local/libexec/openssl10/include
 -I/opt/local/include
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk
 -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE  -I/opt/local/libexec/openssl10/include
 -I/opt/local/include
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk
 -DWITH_TCL_ENABLE_THREAD=1 -fno-common -pipe
 -I/opt/local/libexec/openssl10/include -Os
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk -arch
 x86_64  -fno-common -pipe -fno-common  -arch x86_64 -c tcltklib.c
 tcltklib.c:6246:9: warning: assigning to 'const char *' from 'unsigned
 char *' converts between pointers to integer types with different sign
 [-Wpointer-sign]
       s = Tcl_GetByteArrayFromObj(obj, &len);
         ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 tcltklib.c:6286:40: warning: passing 'const char *' to parameter of type
 'const unsigned char *' converts between pointers to integer types with
 different sign [-Wpointer-sign]
             return Tcl_NewByteArrayObj(s, RSTRING_LEN(str));
                                        ^
 /opt/local/include/tclDecls.h:195:59: note: passing argument to parameter
 'bytes' here
 EXTERN Tcl_Obj *        Tcl_NewByteArrayObj(const unsigned char *bytes,
                                                                  ^
 tcltklib.c:6298:36: warning: passing 'const char *' to parameter of type
 'const unsigned char *' converts between pointers to integer types with
 different sign [-Wpointer-sign]
         return Tcl_NewByteArrayObj(s, RSTRING_LEN(str));
                                    ^
 /opt/local/include/tclDecls.h:195:59: note: passing argument to parameter
 'bytes' here
 EXTERN Tcl_Obj *        Tcl_NewByteArrayObj(const unsigned char *bytes,
                                                                  ^
 tcltklib.c:6387:26: error: implicit declaration of function 'rb_proc_new'
 is invalid in C99 [-Werror,-Wimplicit-function-declaration]
         ret = rb_funcall(rb_proc_new(callq_safelevel_handler, q_dat),
                          ^
 tcltklib.c:6862:26: error: implicit declaration of function 'rb_proc_new'
 is invalid in C99 [-Werror,-Wimplicit-function-declaration]
         ret = rb_funcall(rb_proc_new(evq_safelevel_handler, q_dat),
                          ^
 tcltklib.c:7454:15: warning: assigning to 'char *' from 'unsigned char *'
 converts between pointers to integer types with different sign [-Wpointer-
 sign]
             s = Tcl_GetByteArrayFromObj(tclstr, &len);
               ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 tcltklib.c:8256:26: error: implicit declaration of function 'rb_proc_new'
 is invalid in C99 [-Werror,-Wimplicit-function-declaration]
         ret = rb_funcall(rb_proc_new(ivq_safelevel_handler, q_dat),
                          ^
 tcltklib.c:8337:46: warning: format specifies type 'int' but the argument
 has type 'Tcl_ThreadId' (aka 'struct Tcl_ThreadId_ *') [-Wformat]
     DUMP2("status: Tcl_GetCurrentThread %d", Tcl_GetCurrentThread());
                                         ~~   ^~~~~~~~~~~~~~~~~~~~~~
 tcltklib.c:94:23: note: expanded from macro 'DUMP2'
 fprintf(stderr, ARG1, ARG2); fprintf(stderr, "\n"); fflush(stderr); }
                 ~~~~  ^~~~
 tcltklib.c:10252:27: warning: assigning to 'Tcl_ObjType *' (aka 'struct
 Tcl_ObjType *') from 'const Tcl_ObjType *' (aka 'const struct Tcl_ObjType
 *') discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
     Tcl_ObjType_ByteArray = Tcl_GetObjType(Tcl_ObjTypeName_ByteArray);
                           ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 tcltklib.c:10253:27: warning: assigning to 'Tcl_ObjType *' (aka 'struct
 Tcl_ObjType *') from 'const Tcl_ObjType *' (aka 'const struct Tcl_ObjType
 *') discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
     Tcl_ObjType_String    = Tcl_GetObjType(Tcl_ObjTypeName_String);
                           ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 tcltklib.c:10008:43: warning: shifting a negative signed value is
 undefined [-Wshift-negative-value]
     rb_define_const(ev_flag, "ALL",       INT2FIX(TCL_ALL_EVENTS));
                                           ^~~~~~~~~~~~~~~~~~~~~~~
 ../../ruby.h:143:40: note: expanded from macro 'INT2FIX'
 #define INT2FIX(i) ((VALUE)(((long)(i))<<1 | FIXNUM_FLAG))
                             ~~~~~~~~~~~^
 8 warnings and 3 errors generated.
 }}}

 note I do not think this is a result of the recent openssl changes - it
 would have also happened with the old_openssl PG if the default openssl
 port was installed at build time. The builedbot builds are OK because
 openssl is not in the deps., so will not be installed (only openssl10) and
 thus nothing will be found in the default prefix.

-- 
Ticket URL: <https://trac.macports.org/ticket/63644#comment:6>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list