#40888 closed defect (invalid)
tuntaposx @20111101 fails to build on Mavericks
Reported by: | john@… | Owned by: | macports-tickets@… |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.2.0 |
Keywords: | mavericks | Cc: | ryandesign (Ryan Carsten Schmidt), t21@… |
Port: | tuntaposx |
Description
Error is:
:info:build /usr/bin/clang++ -Wall -mkernel -force_cpusubtype_ALL -fno-builtin -fno-stack-protector -arch x86_64 -DKERNEL -D__APPLE__ -DKERNEL_PRIVATE -DTUNTAP_VERSION=\"20111101\" -DTUN_KEXT_VERSION=\"20111101\" -I.. -I/System/Library/Frameworks/Kernel.framework/Headers -c .> :info:build In file included from In file included from ../tuntap.cc../tuntap.cc::3030: :info:build In file included from : :info:build In file included from ../tuntap.h:35: :info:build ../tuntap.h:35: :info:build ../lock.h:35:10: ../lock.h:35:fatal error: 'kern/locks.h' file not found10: fatal error: 'kern/locks.h' file not found :info:build :info:build #include <kern/locks.h> :info:build ^ :info:build #include <kern/locks.h> :info:build ^ :info:build 1 error generated. :info:build 1 error generated.
(full log attached.)
It looks as though there no longer is a /System/Library/Frameworks/Kernel.framework/Headers
. If I replace that with /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/Kernel.framework/Versions/A/Headers
the build seems fine, but I'm not sure off hand how to do that in a portable way.
Attachments (3)
Change History (13)
Changed 11 years ago by john@…
comment:1 follow-up: 3 Changed 11 years ago by john@…
comment:2 Changed 11 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | ryandesign@… added |
---|---|
Keywords: | mavericks added |
Resolution: | → invalid |
Status: | new → closed |
Agreed, it builds fine for me too.
comment:3 Changed 11 years ago by t21@…
Replying to john@…:
Sorry, my mistake: this is working fine. Unfortunately, I don't seem able to close the issue for myself.
Can you explain what you did to fix this? I see exactly the same error here.
comment:4 Changed 11 years ago by john@…
I hadn't properly installed the XCode Command Line Tools. As per the wiki:Migration guide, you need to run xcode-select --install
-- this is no longer handled through the XCode GUI.
Changed 11 years ago by t21@…
Attachment: | Portfile-tuntaposx.diff added |
---|
Portfile patch to remove need for xcode-select --install (also requires Makefile patch, coming up)
Changed 11 years ago by t21@…
Attachment: | patch-xcode5.diff added |
---|
Patch to remove need for xcode-select --install on Mavericks/Xcode5
comment:5 Changed 11 years ago by t21@…
Thanks John, I suspected that might be it.
I've attached a patch to the Portfile, plus a patch for tuntaposx's Makefiles that removes the need for xcode-select --install.
This is the only port I've come across which requires command-line tools to be installed on Mavericks; I suggest this fix (determining the SDK path at build time) is better than requiring the extra installation step of xcode-select --install.
comment:7 Changed 11 years ago by ryandesign (Ryan Carsten Schmidt)
MacPorts has always required the Xcode command line tools. This is nothing new; the only thing that's new in Mavericks is the method by which users must install them.
comment:8 Changed 11 years ago by t21@…
Indeed it has. But with Mavericks/Xcode5, the shims that are installed by default mean that there's very rarely the need to install anything else.
The only reason this port didn't build is because the source hard-coded the path /System/Library/Frameworks/Kernel.framework/Headers into the Makefiles. As John pointed out, those files exist even without installing the cmdline tools -- under the relevant SDK directory.
I think this is a wider issue for MacPorts architecture: how many ports now fail if you don't install the cmdline tools? Of the 172 I installed on Mavericks, tuntaposx is the only one.
I suggest it's worth considering whether dropping the requirement for xcode-select --install is possible at this stage.
comment:9 Changed 11 years ago by ryandesign (Ryan Carsten Schmidt)
You can bring that idea up on the macports-dev mailing list if you like.
Sorry, my mistake: this is working fine. Unfortunately, I don't seem able to close the issue for myself.