Opened 4 months ago

Closed 3 weeks ago

#57723 closed defect (fixed)

tuntaposx @20150118: fatal error: 'kern/locks.h' file not found

Reported by: mriyah Owned by: Equidamoid
Priority: Normal Milestone:
Component: ports Version: 2.5.4
Keywords: mojave Cc: mriyah, jackiezhangcn
Port: tuntaposx

Description (last modified by mf2k (Frank Schima))

tuntaposx as a dependency failed to build with the following

fatal error: 'kern/locks.h' file not found.

Regards.

Attachments (1)

main.log (18.0 KB) - added by mriyah 4 months ago.

Download all attachments as: .zip

Change History (11)

comment:1 Changed 4 months ago by mf2k (Frank Schima)

Description: modified (diff)
Port: tuntaposx added

In the future, please use WikiFormatting, fill in the Port field and add the port maintainer(s) to Cc (port info --maintainers tuntaposx), if any.

comment:2 Changed 4 months ago by mf2k (Frank Schima)

Please attach the main.log file after cleaning the port (sudo port clean tuntaposx).

Changed 4 months ago by mriyah

Attachment: main.log added

comment:3 Changed 4 months ago by ryandesign (Ryan Schmidt)

Keywords: mojave added
Summary: installing tinc on mojavetuntaposx @20150118: fatal error: 'kern/locks.h' file not found

comment:4 Changed 3 months ago by mf2k (Frank Schima)

Cc: jackiezhangcn added

Has duplicate #57819.

comment:5 Changed 4 weeks ago by Equidamoid

The build uses incorrect path for kernel headers:

-I/System/Library/Frameworks/Kernel.framework/Headers

instead of the one that made it compile for me:

-I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/Kernel.framework/Versions/A/Headers

I have no idea (for now) how to fix it properly in macports way, but here is the hack that may help someone before proper fix is available:

Run port edit tuntaposx and replace

reinplace "s|@ARCHFLAGS@|[get_canonical_archflags cc]|" ${f}

with

reinplace "s|@ARCHFLAGS@|[get_canonical_archflags cc] -I/Library/Developer/CommandLineTools/SDKs/MacOSX. sdk/System/Library/Frameworks/Kernel.framework/Versions/A/Headers|" ${f}

comment:6 Changed 4 weeks ago by Equidamoid

I believe this line in `src/{tun,tap}/Makefile can be patched for a better fix:

INCLUDE = -I.. -I/System/Library/Frameworks/Kernel.framework/Headers

Version 0, edited 4 weeks ago by Equidamoid (next)

comment:8 Changed 4 weeks ago by Equidamoid

Owner: set to Equidamoid
Resolution: fixed
Status: newclosed

In 7640a4aa1377008845014c2bdfab91900d031fd5/macports-ports (master):

Fix tuntaposx build on Mojave

  • updated kernel headers path in Makefies

Closes: #57723

comment:9 Changed 4 weeks ago by jmroot (Joshua Root)

Resolution: fixed
Status: closedreopened

comment:10 Changed 3 weeks ago by ken-cunningham-webuse

Resolution: fixed
Status: reopenedclosed

In 085ffd96809875035301b00a728c98783f773e19/macports-ports (master):

tuntaposx: use configure.sdkroot to set SDK path

closes: #57723

when this port is next updated, these patches and
reinplace bits should all be rolled into one.

Note: See TracTickets for help on using tickets.