pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Setting TERMCAP location



> Hi,
> 
> Looks like Apple changed the location where the TERMCAP headers live
> on Mavericks.
> 
> $ locate termcap.h
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/usr/include/termcap.h
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include/termcap.h
> 
> Meaning the header files are now only available within the SDK and not
> in /usr/include.
> 
> The library itself is available in the SDKs and in /usr/lib:
> 
> $ locate termcap.dylib
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk/usr/lib/libtermcap.dylib
> /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/lib/libtermcap.dylib
> /usr/lib/libtermcap.dylib
> 
> That leads to a build failure on all packages that require TERMCAP.
> 
> $ bmake
> ERROR: This package has set PKG_FAIL_REASON:
> ERROR: No usable termcap library found on the system.
> *** Error code 1
> 
> Stop.
> bmake: stopped in /Users/markus/pkgsrc/databases/sqlite3
> 
> What's the best way to tell pkgsrc how to find the headers?
> 
> Thanks,
> -Markus

Hello,

I always use -isysroot on Mac OS X. In mk.conf add something like the following:

OSXVER= 10.9
XCODE=  /Applications/Xcode.app/Contents/Developer
XCBIN=  ${XCODE}/Toolchains/XcodeDefault.xctoolchain/usr
XCSDK=  ${XCODE}/Platforms/MacOSX.platform/Developer/SDKs/MacOSX${OSXVER}.sdk
CFLAGS+=        -isysroot ${XCSDK}
CPPFLAGS+=      -isysroot ${XCSDK}
FFLAGS+=        -isysroot ${XCSDK}
LDFLAGS+=       -Wl,-syslibroot,${XCSDK}

You might also want to create a symbolic link to /usr/include (so built-in 
packages are detected correctly):

sudo ln -s -f 
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk
 /usr/include

That way you don't need to install Command Line Tools for Xcode.

Kind regards,
Adam


Home | Main Index | Thread Index | Old Index