Wireshark-dev: Re: [Wireshark-dev] Mac Build Error
From: Alexis La Goutte <alexis.lagoutte@xxxxxxxxx>
Date: Wed, 20 Jan 2016 16:14:17 +0100


On Wed, Jan 20, 2016 at 3:48 PM, David Morsberger <dave@xxxxxxxxxxxxxx> wrote:


On Wed, Jan 20, 2016 at 8:43 AM, Stig Bjørlykke <stig@xxxxxxxxxxxxx> wrote:
On Wed, Jan 20, 2016 at 1:47 PM, David Morsberger <dave@xxxxxxxxxxxxxx> wrote:
 
I am getting actual errors within Xcode after ‘cmake -G Xcode’. This can easily be resolved by not testing ‘—as-needed’ or ‘—pie’ when XCODE just like what is done for MSVC.

Ah, yes, I forgot about this.  I have tried to fix this earlier without luck.


I have a local fix in my cmake build directory for this flags, I manually changed this lines in CMakeCache.txt:

WS_LD_FLAG_VALID0:INTERNAL=0
WS_LD_FLAG_VALID1:INTERNAL=0
 
A correct fix for this would be nice.




My current workaround is the following change to CMakeLists.txt :
-if(NOT CMAKE_C_COMPILER_ID MATCHES "MSVC")
+if(NOT (CMAKE_C_COMPILER_ID MATCHES "MSVC" OR XCODE))
 	set(WIRESHARK_LD_FLAGS
 		-Wl,--as-needed

I still want to know what is going on because there has to be a way to find out when the compile/link check fails.

The fix look good for me (and can be push on gerrit)
 

___________________________________________________________________________
Sent via:    Wireshark-dev mailing list <wireshark-dev@xxxxxxxxxxxxx>
Archives:    https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
             mailto:wireshark-dev-request@xxxxxxxxxxxxx?subject=unsubscribe