Opened 10 years ago

Closed 9 years ago

#47168 closed defect (fixed)

wireshark build can not detect xcode 10.10 sdk

Reported by: hofione@… Owned by: opendarwin.org@…
Priority: Normal Milestone:
Component: ports Version: 2.3.3
Keywords: Cc: hsivank@…, mndavidoff (Monte Davidoff), layer@…, Schamschula (Marius Schamschula), rectalogic (Andrew Wason)
Port: wireshark

Description (last modified by mf2k (Frank Schima))

sudo xcode-select -s /xcode_6_2/Xcode.app   (tried also 6_1_1 and 6_3_beta3)
sudo xcodebuild -license

sudo port sync
sudo port selfupdate
sudo port upgrade outdated
sudo port uninstall wireshark
sudo port clean wireshark

sudo port install wireshark
Error: Failed to configure wireshark, consult /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_net_wireshark/wireshark/work/wireshark-1.12.4/config.log
(log file attached)

:info:configure checking whether we can build for OS X 10.10... no
:info:configure configure: error: We couldn't find the SDK for OS X 10.10

xcode and command line tools installed perfectly, any other target using 10.10 sdk builds fine

Attachments (3)

config.log (89.6 KB) - added by hofione@… 10 years ago.
patch-configure.xcode.diff (404 bytes) - added by mndavidoff (Monte Davidoff) 9 years ago.
Portfile.diff (254 bytes) - added by mndavidoff (Monte Davidoff) 9 years ago.

Download all attachments as: .zip

Change History (19)

Changed 10 years ago by hofione@…

Attachment: config.log added

comment:1 Changed 10 years ago by mf2k (Frank Schima)

Owner: changed from macports-tickets@… to opendarwin.org@…
Port: wireshark added

In the future, please fill in the Port field and Cc the port maintainers (port info --maintainers wireshark), if any.

comment:2 Changed 10 years ago by mf2k (Frank Schima)

Description: modified (diff)

comment:3 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: hsivank@… added

comment:4 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Looks like they're hardcoding the locations in which to look for the SDKs and not taking an xcode-selected path into consideration. From configure.ac:

		for i in /Developer/SDKs \
		    /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs \
		    /Library/Developer/CommandLineTools/SDKs
		do
			if test -d "$i"/"MacOSX$deploy_target.sdk"
			then
				SDKPATH="$i"/"MacOSX$deploy_target.sdk"
				break
			fi
		done
		if test -z "$SDKPATH"
		then
			AC_MSG_RESULT(no)
			AC_MSG_ERROR([We couldn't find the SDK for OS X $deploy_target])
		fi
		AC_MSG_RESULT(yes)

comment:5 Changed 9 years ago by mndavidoff (Monte Davidoff)

Cc: md14-macports@… added

Cc Me!

Changed 9 years ago by mndavidoff (Monte Davidoff)

Attachment: patch-configure.xcode.diff added

comment:6 Changed 9 years ago by mndavidoff (Monte Davidoff)

I've attached a patch to fix this problem.

I ran into this issue after installing Xcode 7.0 on OS X 10.10, noticing wireshark didn't build, installing Xcode 6.4, and using sudo xcode-select -s to switch to Xcode 6.4.

comment:7 Changed 9 years ago by ghosthound

Hmm, the attached patch didn't work for me, looks like w/ Xcode 7.0 on 10.10.5 the only SDK installed (by default) is

/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk

which doesn't work as configure is looking for the 10.10 SDK.

comment:8 in reply to:  7 Changed 9 years ago by mndavidoff (Monte Davidoff)

Replying to ricci@…:

the attached patch didn't work for me, looks like w/ Xcode 7.0 on 10.10.5 the only SDK installed ... is MacOSX10.11.sdk

Yes, I'm also using OS X 10.10.5 with Xcode 7.0 installed. In order to build wireshark with the patch, first:

  1. Download and install Xcode 6.4 from Downloads for Apple Developers. Install Xcode 6.4 in an alternate location, for example, /Applications/Xcode-6.4/Xcode.app.
  2. Download and install Command Line Tools (OX X 10.10) for Xcode 6.4 from the same place.
  3. Switch to Xcode6.4.
    $ sudo xcode-select -s /PATH/TO/XCODE64/Xcode.app
    

comment:9 Changed 9 years ago by raimue (Rainer Müller)

Apparently it is correct Apple only ships the 10.11 SDK with Xcode 7 (macports-users).

This problem can be avoided by disabling the deployment target completely. As we build our binary archives only for a single version of OS X it should not be necessary.

Index: Portfile
===================================================================
--- Portfile	(revision 140341)
+++ Portfile	(working copy)
@@ -43,6 +43,7 @@
 		port:zlib
 
 configure.args	\
+		--disable-osx-deploy-target \
 		--without-libsmi \
 		--disable-usr-local \
 		--without-adns \

comment:10 Changed 9 years ago by layer@…

Cc: layer@… added

Cc Me!

comment:11 Changed 9 years ago by Schamschula (Marius Schamschula)

Cc: mschamschula@… added

Cc Me!

comment:12 Changed 9 years ago by virtan@…

This should help

sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk

Changed 9 years ago by mndavidoff (Monte Davidoff)

Attachment: Portfile.diff added

comment:13 in reply to:  9 Changed 9 years ago by mndavidoff (Monte Davidoff)

Replying to raimue@…:

This problem can be avoided by disabling the deployment target completely.

A much better solution! Your patch works for me. To test, I did a sudo xcode-select -r, removed Xcode 6.4, and then installed wireshark. I've replaced the Portfile.diff attachment with your patch. (The patch-configure.xcode.diff​ attachment is no longer needed.)

comment:14 Changed 9 years ago by rectalogic (Andrew Wason)

Cc: rectalogic@… added

Cc Me!

comment:15 Changed 9 years ago by ghosthound

The addition of '--disable-osx-deploy-target' as proposed raimue@ seems to work for me as well (Xcode 7 on OS X 10.10.5). It will get added once svn is back up.

comment:16 Changed 9 years ago by ghosthound

Resolution: fixed
Status: newclosed

resolved in r141357, at least on 10.10 with Xcode 7. Please reopen if there's a combo that doesn't work.

Note: See TracTickets for help on using tickets.