Opened 14 years ago

Last modified 5 years ago

#26224 new defect

zlib fails to configure shared library when using 'configuredistcc yes'

Reported by: aj@… Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 1.9.1
Keywords: Cc: landonf (Landon Fuller)
Port: zlib

Description

fresh install of macports. building zlib fails on make install on a copy $SHAREDLV line where $SHAREDLV is null.

Running configure manually in the build dir configures zlib properly to build the shared library and fill out the makefile properly. You can then use ports to install zlib, as make install will run correctly.

Attachments (1)

main.log (18.5 KB) - added by aj@… 14 years ago.
zlib build failure

Download all attachments as: .zip

Change History (12)

comment:1 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: landonf@… added
Owner: changed from macports-tickets@… to ryandesign@…

Please Cc port maintainers.

In the past, I believe this problem was caused by attempting to install zlib while Xcode was not properly installed, then installing Xcode properly, then re-attempting to install zlib without having first cleaned it.

So please ensure the correct version of Xcode for your OS version is installed properly, clean zlib, and try again, and let us know if that works or not. If not, attach the main.log file.

Changed 14 years ago by aj@…

Attachment: main.log added

zlib build failure

comment:2 Changed 14 years ago by aj@…

XCode is v3.2.2 gcc: is i686-apple-darwin10-gcc-4.2.1

comment:3 Changed 14 years ago by aj@…

Line 40 in the main.log is where the configuration error happens

comment:4 Changed 14 years ago by jmroot (Joshua Root)

Summary: zlib fails to configure shared libraryzlib fails to configure shared library when using 'configuredistcc yes'

comment:5 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

I've never tried using distcc. Do you see the same problem without it?

comment:6 Changed 14 years ago by aj@…

Indeed. That's it. It works fine without distcc on. Somehow the distcc failure kills the config. probably kills something in the environment or fails to set something up when distcc fails.

comment:7 Changed 14 years ago by dmitrij.ledkov@…

Building with configure.compiler=clang installs only .a and .so. Building with default gcc-4.2 compiler install dylib. There is a makefile patch. Probably it needs updating.

comment:8 Changed 14 years ago by dmitrij.ledkov@…

test -z "$CC" && echo Checking for ${CROSS_PREFIX}gcc...
cc=${CC-${CROSS_PREFIX}gcc}
cflags=${CFLAGS-"-O3"}
# to force the asm version use: CFLAGS="-O3 -DASMV" ./configure                 
case "$cc" in
  *gcc*) gcc=1 ;;
esac


if test "$gcc" -eq 1 && ($cc -c $cflags $test.c) 2>/dev/null; then

dylib options in the darwin case

else

no darwin case

endif

This is in the hand-written configure script. So if we are building with something that is not gcc, we are not getting dylib =(

comment:9 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

Changing a port's compiler is not something a user should be doing and is not supported (unless the port offers variants for doing that, which zlib does not).

comment:10 in reply to:  8 Changed 5 years ago by ryandesign (Ryan Carsten Schmidt)

Replying to dmitrij.ledkov@…:

Building with configure.compiler=clang installs only .a and .so. Building with default gcc-4.2 compiler install dylib. There is a makefile patch. Probably it needs updating.

Replying to dmitrij.ledkov@…:

test -z "$CC" && echo Checking for ${CROSS_PREFIX}gcc...
cc=${CC-${CROSS_PREFIX}gcc}
cflags=${CFLAGS-"-O3"}
# to force the asm version use: CFLAGS="-O3 -DASMV" ./configure                 
case "$cc" in
  *gcc*) gcc=1 ;;
esac


if test "$gcc" -eq 1 && ($cc -c $cflags $test.c) 2>/dev/null; then

dylib options in the darwin case

else

no darwin case

endif

This is in the hand-written configure script. So if we are building with something that is not gcc, we are not getting dylib =(

This is an unrelated issue which was filed separately as #28656 and fixed.

comment:11 in reply to:  6 Changed 5 years ago by ryandesign (Ryan Carsten Schmidt)

Back to the original issue this ticket was about:

Replying to aj@…:

Indeed. That's it. It works fine without distcc on. Somehow the distcc failure kills the config. probably kills something in the environment or fails to set something up when distcc fails.

Is this still a problem with the latest version of zlib, 1.2.11, and the latest version of distcc, 3.3.3?

Note: See TracTickets for help on using tickets.