Opened 11 years ago

Closed 11 years ago

#42158 closed defect (fixed)

libbiosig: build fails with universal variant

Reported by: ryandesign (Ryan Carsten Schmidt) Owned by: neurodroid (Christoph Schmidt-Hieber)
Priority: Normal Milestone:
Component: ports Version: 2.2.1
Keywords: Cc:
Port: libbiosig

Description

  ld: warning: ignoring file
  CMakeFiles/cmTryCompileExec713066221.dir/testCCompiler.c.o, file was built
  for unsupported file format ( 0xCF 0xFA 0xED 0xFE 0x07 0x00 0x00 0x01 0x03
  0x00 0x00 0x00 0x01 0x00 0x00 0x00 ) which is not the architecture being
  linked (i386): CMakeFiles/cmTryCompileExec713066221.dir/testCCompiler.c.o

  Undefined symbols for architecture i386:

    "_main", referenced from:
       implicit entry/start for main executable

  ld: symbol(s) not found for architecture i386

Attachments (3)

main.log (13.7 KB) - added by ryandesign (Ryan Carsten Schmidt) 11 years ago.
patch-v3.diff (2.7 KB) - added by neurodroid (Christoph Schmidt-Hieber) 11 years ago.
More general patch that uses the private getline implementation only on SL and independently of MacPorts. See ticket #42152.
Portfile-libbiosig.diff (1.1 KB) - added by neurodroid (Christoph Schmidt-Hieber) 11 years ago.
libbiosig Portfile diff to use only system zlib

Download all attachments as: .zip

Change History (6)

Changed 11 years ago by ryandesign (Ryan Carsten Schmidt)

Attachment: main.log added

comment:1 Changed 11 years ago by neurodroid (Christoph Schmidt-Hieber)

That's odd. CMake compiles "without" arch flags although CMAKE_OSX_ARCHITECTURES is set to "x86_64;i386":

/usr/bin/clang -DMACPORTS -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk
-mmacosx-version-min=10.9 -o 
CMakeFiles/cmTryCompileExec3523348986.dir/testCCompiler.c.o -c

But then it links with arch flags:

/usr/bin/clang -DMACPORTS -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk
-mmacosx-version-min=10.9 -Wl,-search_paths_first
-Wl,-headerpad_max_install_names -L/opt/local/lib
-Wl,-headerpad_max_install_names -lz -lcholmod
-Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk
-arch x86_64 -arch i386
CMakeFiles/cmTryCompileExec3523348986.dir/testCCompiler.c.o -o
cmTryCompileExec3523348986

Any ideas?

Version 0, edited 11 years ago by neurodroid (Christoph Schmidt-Hieber) (next)

Changed 11 years ago by neurodroid (Christoph Schmidt-Hieber)

Attachment: patch-v3.diff added

More general patch that uses the private getline implementation only on SL and independently of MacPorts. See ticket #42152.

Changed 11 years ago by neurodroid (Christoph Schmidt-Hieber)

Attachment: Portfile-libbiosig.diff added

libbiosig Portfile diff to use only system zlib

comment:2 Changed 11 years ago by neurodroid (Christoph Schmidt-Hieber)

Apologies, the attached files belong to ticket #42159.

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

Resolution: fixed
Status: newclosed

The problem is the portfile overrides the cflags and cxxflags the portgroup sets. Fixed in r117319.

Note: See TracTickets for help on using tickets.