Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#46815 closed defect (invalid)

Selfupdate still fails on "readline in /usr/local" after cleanout

Reported by: dsmithhfx@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: base Version: 2.0.3
Keywords: Cc:
Port:

Description (last modified by ryandesign (Ryan Carsten Schmidt))

Hi,

I can't get port version 2.03 (OSX10.4.11/ppc/G5 tower) to selfupdate, it fails with

make[2]: *** [registry.dylib] Error 1
make[1]: *** [all] Error 1
make: *** [all] Error 1
shell command "cd /opt/local/var/macports/sources/rsync.macports.org/release/base && CC=/usr/bin/cc ./configure --prefix=/opt/local --with-tclpackage=/Library/Tcl --with-install-user=root --with-install-group=admin --with-directory-mode=0755 && make && make install SELFUPDATING=1" returned error 2
DEBUG: Error installing new MacPorts base: shell command failed (see log for details)
    while executing
"macports::selfupdate [array get global_options] base_updated"
Error: /opt/local/bin/port: port selfupdate failed: Error installing new MacPorts base: shell command failed (see log for details)

After some digging through tickets e.g. #11742, it appears that readline may be the culprit. Early in the selfupdate output there appears

--->  MacPorts base is outdated, installing new version 2.3.3
DEBUG: Permissions OK
Warning: Disabling readline support due to readline in /usr/local

Even after completely clearing all instances of *readline" from my /usr directory (so

sudo find /usr -name "*readline*"

returns nothing, and

sudo port -f deactivate readline

I'm really stuck here, running really outdated apache2 etc. Any help appreciated!

Attachments (2)

Selfupdate-Output-021015-2.txt (383.7 KB) - added by dsmithhfx@… 10 years ago.
config.log (79.9 KB) - added by dsmithhfx@… 10 years ago.

Download all attachments as: .zip

Change History (7)

Changed 10 years ago by dsmithhfx@…

comment:1 Changed 10 years ago by neverpanic (Clemens Lang)

Problem is

/usr/bin/cc -dynamiclib -g -O2 -std=c99 -Wextra -Wall -pedantic    -Wl,-single_module registry.o util.o entry.o entryobj.o file.o fileobj.o portgroup.o portgroupobj.o -o registry.dylib -L/opt/local/var/macports/sources/rsync.macports.org/release/base/vendor/tcl8.5.15/unix -ltclstub8.5  -install_name @loader_path/../registry2.0/registry.dylib  -lsqlite3 ../cregistry/cregistry.a
ld: Undefined symbols:
_sqlite3_prepare_v2
_sqlite3_extended_result_codes
/usr/libexec/gcc/powerpc-apple-darwin8/4.0.1/libtool: internal link edit command failed
make[2]: *** [registry.dylib] Error 1
make[1]: *** [all] Error 1
make: *** [all] Error 1

It seems your version of sqlite3 is too old to support sqlite3_prepare_v2. MacPorts has a configure-time check to fall back to sqlite3_prepare if it isn't available, but that seems to have failed in your case. Please attach /opt/local/var/macports/sources/rsync.macports.org/release/base/config.log.

Do you happen to have an sqlite3.h somewhere in /usr/local, because it seems the newer header is available, but the newer library isn't (or isn't being found).

Changed 10 years ago by dsmithhfx@…

Attachment: config.log added

comment:2 in reply to:  1 Changed 10 years ago by dsmithhfx@…

Replying to cal@…: Thanks for responding!

sudo find /usr -name "*sqlite3*"
/usr/bin/sqlite3
/usr/include/sqlite3.h
/usr/lib/libsqlite3.0.8.6.dylib
/usr/lib/libsqlite3.0.dylib
/usr/lib/libsqlite3.dylib
/usr/lib/sqlite3
/usr/lib/sqlite3/libtclsqlite3.dylib
/usr/local/bin/sqlite3
/usr/local/include/sqlite3.h
/usr/local/include/sqlite3ext.h
/usr/local/lib/libsqlite3.0.8.6.dylib
/usr/local/lib/libsqlite3.0.dylib
/usr/local/lib/libsqlite3.a
/usr/local/lib/libsqlite3.dylib
/usr/local/lib/libsqlite3.la
/usr/local/lib/pkgconfig/sqlite3.pc
[bunch of ruby gems]
/usr/share/man/man1/sqlite3.1

config.log attached

comment:3 Changed 10 years ago by neverpanic (Clemens Lang)

Resolution: invalid
Status: newclosed

Yeah, the check picks up the sqlite3.h from your sqlite installation in /usr/local, but the link happens against /usr/lib/libsqlite3.dylib, so it fails.

Move /usr/local/include aside for a while and re-try and it'll work. We don't support having stuff in /usr/local for precisely this reason. We cannot easily make the compiler ignore these locations.

comment:4 in reply to:  3 Changed 10 years ago by dsmithhfx@…

Replying to cal@…: That worked. Thanks!

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

Description: modified (diff)
Keywords: selfupdate removed
Note: See TracTickets for help on using tickets.