Pkcs11Interop / pkcs11-logger

PKCS#11 logging proxy module
Apache License 2.0
42 stars 14 forks source link

Build on macOS now fails since 32-bits support has been removed by Apple #7

Closed LudovicRousseau closed 2 years ago

LudovicRousseau commented 5 years ago

On macOS Mojave 10.14 , if I follow the build instructions I get:

$ cd build/osx
$ sh build.sh 
rm -f *.o
rm -f *.dylib
gcc -m32 -Wall -Wextra -Werror -O2 -I../../src -fPIC -c ../../src/init.c
gcc -m32 -Wall -Wextra -Werror -O2 -I../../src -fPIC -c ../../src/lock.c
gcc -m32 -Wall -Wextra -Werror -O2 -I../../src -fPIC -c ../../src/log.c
gcc -m32 -Wall -Wextra -Werror -O2 -I../../src -fPIC -c ../../src/pkcs11-logger.c
gcc -m32 -Wall -Wextra -Werror -O2 -I../../src -fPIC -c ../../src/translate.c
gcc -m32 -Wall -Wextra -Werror -O2 -I../../src -fPIC -c ../../src/utils.c
gcc -m32 -dynamiclib -o pkcs11-logger-x86.dylib \
    -Wl,-exported_symbols_list,pkcs11-logger.symbols \
    init.o lock.o log.o pkcs11-logger.o translate.o utils.o \
    -lc -ldl -lpthread
ld: warning: The i386 architecture is deprecated for macOS (remove from the Xcode build setting: ARCHS)
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libdl.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libdl.tbd
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libpthread.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libpthread.tbd
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libc.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libc.tbd
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libSystem.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libSystem.tbd
Undefined symbols for architecture i386:
  "___bzero", referenced from:
      _pkcs11_logger_log_nonzero_string in log.o
      _pkcs11_logger_translate_ck_byte_ptr in translate.o
      _pkcs11_logger_utils_get_current_time_str in utils.o
  "___cxa_atexit", referenced from:
      ___GLOBAL_init_65535 in init.o
[...]
jariq commented 2 years ago

Fixed in master.