[MacPorts] #59397: openssh @8.1_1: fails to build on 10.6: audit-bsm.c:66:10: fatal error: 'bsm/audit_session.h' file not found

MacPorts noreply at macports.org
Thu Oct 24 18:54:17 UTC 2019


#59397: openssh @8.1_1: fails to build on 10.6: audit-bsm.c:66:10: fatal error:
'bsm/audit_session.h' file not found
-------------------------+-------------------------
  Reporter:  grumpybozo  |      Owner:  Ionic
      Type:  defect      |     Status:  closed
  Priority:  Normal      |  Milestone:
 Component:  ports       |    Version:  2.6.1
Resolution:  fixed       |   Keywords:  snowleopard
      Port:  openssh     |
-------------------------+-------------------------

Comment (by grumpybozo):

 Round Four!
 \\
 Including <Security/SecItem.h> fixes some of this, but leaves
 kSecClassGenericPassword undefined, as it is only in 10.7+


 {{{
 ccache /opt/local/bin/clang-mp-9.0 -o sftp-server sftp-server.o sftp-
 common.o sftp-realpath.o sftp-server-main.o -L. -Lopenbsd-compat/
 -L/opt/local/lib -L/opt/local/lib -L/opt/local/lib
 -Wl,-headerpad_max_install_names -Wl,-search_paths_first -arch i386
 -fstack-protector-strong -pie  -lssh -lopenbsd-compat -lcrypto -lbsm -lz
 -L/opt/local/lib -Wl,-headerpad_max_install_names -arch i386
 -L/opt/local/lib  -L/lib  -lssl  -lcrypto -lldns -lresolv
 ccache /opt/local/bin/clang-mp-9.0 -o sftp progressmeter.o sftp.o sftp-
 client.o sftp-common.o sftp-glob.o -L. -Lopenbsd-compat/ -L/opt/local/lib
 -L/opt/local/lib -L/opt/local/lib -Wl,-headerpad_max_install_names
 -Wl,-search_paths_first -arch i386 -fstack-protector-strong -pie  -lssh
 -lopenbsd-compat -lcrypto -lbsm -lz  -L/opt/local/lib
 -Wl,-headerpad_max_install_names -arch i386  -L/opt/local/lib  -L/lib
 -lssl  -lcrypto -lldns -lresolv -L/opt/local/lib -ledit
 clang: warning: argument unused during compilation: '-pie' [-Wunused-
 command-line-argument]
 clang: warning: argument unused during compilation: '-pie' [-Wunused-
 command-line-argument]
 ld: warning: directory not found for option '-L/lib'
 ld: warning: directory not found for option '-L/lib'
 keychain.m:83:15: error: use of undeclared identifier 'kSecClass'
                                (id)kSecClass:
 (id)kSecClassGenericPassword,
                                    ^
 keychain.m:94:8: warning: implicit declaration of function
 'SecItemCopyMatching' is invalid in C99 [-Wimplicit-function-declaration]
         ret = SecItemCopyMatching((CFDictionaryRef)searchQuery, (CFTypeRef
 *)&passphraseData);
               ^
 keychain.m:141:9: error: use of undeclared identifier 'kSecClass'
                                 (id)kSecClass:
 (id)kSecClassGenericPassword,
                                     ^
 keychain.m:152:44: error: use of undeclared identifier 'kSecReturnRef'
         NSMutableDictionary *searchQuery = [@{(id)kSecReturnRef: @YES}
 mutableCopy];
                                                   ^
 keychain.m:156:8: warning: implicit declaration of function
 'SecItemCopyMatching' is invalid in C99 [-Wimplicit-function-declaration]
         ret = SecItemCopyMatching((CFDictionaryRef)searchQuery,
 &searchResults);
               ^
 keychain.m:172:33: error: use of undeclared identifier 'kSecValueData'
                 NSDictionary *changes = @{(id)kSecValueData: [NSData
 dataWithBytesNoCopy: (void *)passphrase length: strlen(passphrase)
 freeWhenDone: NO]};
                                               ^
 keychain.m:174:9: warning: implicit declaration of function
 'SecItemUpdate' is invalid in C99 [-Wimplicit-function-declaration]
                 ret = SecItemUpdate((CFDictionaryRef)updateQuery,
 (CFDictionaryRef)changes);
                       ^
 keychain.m:181:42: error: use of undeclared identifier 'kSecValueData'
                 NSMutableDictionary *addQuery = [@{(id)kSecValueData:
 [NSData dataWithBytesNoCopy: (void *)passphrase length: strlen(passphrase)
 freeWhenDone: NO]} mutableCopy];
                                                        ^
 keychain.m:184:9: warning: implicit declaration of function 'SecItemAdd'
 is invalid in C99 [-Wimplicit-function-declaration]
                 ret = SecItemAdd((CFDictionaryRef)addQuery, NULL);
                       ^
 keychain.m:209:15: error: use of undeclared identifier 'kSecClass'
                                (id)kSecClass:
 (id)kSecClassGenericPassword,
                                    ^
 keychain.m:218:8: warning: implicit declaration of function
 'SecItemDelete' is invalid in C99 [-Wimplicit-function-declaration]
         ret = SecItemDelete((CFDictionaryRef)searchQuery);
               ^
 keychain.m:235:9: error: use of undeclared identifier 'kSecClass'
                                 (id)kSecClass:
 (id)kSecClassGenericPassword,
                                     ^
 keychain.m:245:8: warning: implicit declaration of function
 'SecItemCopyMatching' is invalid in C99 [-Wimplicit-function-declaration]
         err = SecItemCopyMatching((CFDictionaryRef)searchQuery, (CFTypeRef
 *)&searchResults);
               ^
 keychain.m:255:48: error: use of undeclared identifier 'kSecAttrAccount'
                 NSString        *accountString =
 itemAttributes[(id)kSecAttrAccount];
                                                                     ^
 6 warnings and 8 errors generated.
 make: *** [keychain.o] Error 1
 }}}

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


More information about the macports-tickets mailing list