Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#18752 closed defect (invalid)

libiconv fails to build because configure.cc not set

Reported by: dale+macports@… Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 1.7.0
Keywords: Cc: MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Port: libiconv

Description

When trying to port -f upgrade libiconv:

Warning: Group file could not be located.
Warning: Group file could not be located.
--->  Fetching libiconv
--->  Verifying checksum(s) for libiconv
--->  Extracting libiconv
--->  Applying patches to libiconv
--->  Configuring libiconv
--->  Building libiconv with target all
Error: Target org.macports.build returned: shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_textproc_libiconv/work/libiconv-1.12" && make CC= -f Makefile.devel && make -j3 all " returned error 2
Command output: O lib/genaliases.c -o genaliases
make: O: Command not found
make: [lib/aliases.h] Error 127 (ignored)
./genaliases > lib/aliases.gperf 3> canonical.sh 4> canonical_local.sh
/bin/sh: ./genaliases: No such file or directory
make: *** [lib/aliases.h] Error 127

Error: Unable to upgrade port: 1

Note CC= with no value. I know next to nothing about MacPorts, but I suspect this error occurs because the Portfile uses ${configure.cc} in a place where it is not set. The attached patch applied to the Portfile allows me to rebuild libiconv successfully.

Attachments (1)

libiconv-cc.patch (651 bytes) - added by dale+macports@… 15 years ago.
Move reference to configure.cc into a post-configure block in the Portfile

Download all attachments as: .zip

Change History (9)

Changed 15 years ago by dale+macports@…

Attachment: libiconv-cc.patch added

Move reference to configure.cc into a post-configure block in the Portfile

comment:1 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Cc: mcalhoun@… added

Cc Me!

comment:2 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Owner: changed from macports-tickets@… to ryandesign@…

In previous versions of MacPorts, configure.cc was not defined until the configure stage.
In the latest version, however, configure.cc should be defined earlier.

By chance, are you running an older version of MacPorts?

I believe your patch would fail if the user ran

port configure && port build

comment:3 in reply to:  2 Changed 15 years ago by dale+macports@…

Replying to mcalhoun@...:

By chance, are you running an older version of MacPorts?

I don't think so?

$ port version
Version: 1.700
$ uname -a
Darwin dale 9.6.0 Darwin Kernel Version 9.6.0: Mon Nov 24 17:37:00 PST 2008; root:xnu-1228.9.59~1/RELEASE_I386 i386

And I've done port -d selfupdate several times today.

However I totally buy your explanation that something is up, because I've got port upgrade outdated running and a ton of ports are failing like this:

--->  Building py25-zlib with target build
Error: Target org.macports.build returned: shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_python_py25-zlib/work/Python-2.5.4/Modules" && /opt/local/bin/python2.5 setup.py build " returned error 1
Command output: running build
running build_ext
building 'zlib' extension
-DNDEBUG -g -O3 -Wall -Wstrict-prototypes -I/opt/local/include -I/opt/local/Library/Frameworks/Python.framework/Versions/2.5/include/python2.5 -c zlibmodule.c -o build/temp.macosx-10.3-i386-2.5/zlibmodule.o
unable to execute -DNDEBUG: No such file or directory
error: command '-DNDEBUG' failed with exit status 1

This smells to me like my compiler isn't getting defined in the right place somehow, and not a problem with the libiconv port. If someone knowledgeable concurs with this statement, please feel free to close this ticket as invalid.

comment:4 Changed 15 years ago by blb@…

Did you install MacPorts from trunk at some point? Check the install date for /opt/local/bin/port, if it's older than 2008-12-13 then you should at least update to the DMG of 1.7.0.

comment:5 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Has the previous suggestion fixed the problem?

comment:6 in reply to:  5 Changed 15 years ago by dale+macports@…

Replying to mcalhoun@...:

Has the previous suggestion fixed the problem?

It has, my apologies for not responding sooner. I did indeed build MacPorts from trunk in the era of the TCL bug in 1.6. I am surprised that port -d selfupdate didn't pick up the new 1.7.0 release and replace /opt/local/bin/port for me; perhaps that's because it thought I was already running 1.7.0.

libiconv now builds fine. Please close this ticket as invalid. Sorry for the trouble, thanks for the help!

comment:7 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Resolution: invalid
Status: newclosed

Glad everything is working.

comment:8 Changed 15 years ago by (none)

Milestone: Port Bugs

Milestone Port Bugs deleted

Note: See TracTickets for help on using tickets.