壊れた関係。

SQLite3のPortがこないだからアップグレードしようとしてもエラーになって、ビルドできなかった。

$ sudo port upgrade sqlite3
Password:
--->  Building sqlite3 with target all
Error: Target com.apple.build returned: shell command "cd "/opt/local/var/db/dports/build/_opt_local_var_db_dports_sources_rsync.rsync.macports.org_dpupdate_dports_databases_sqlite3/work/sqlite-3.3.17" && CFLAGS="-I/opt/local/include/ -DSQLITE_ENABLE_LOCKING_STYLE=1" LDFLAGS="-L/opt/local/lib" gnumake all" returned error 2
Command output: ./libtool --mode=link /usr/bin/gcc-4.0 -g -O2 -I. -I./src -DNDEBUG   -DTHREADSAFE=1 -DSQLITE_THREAD_OVERRIDE_LOCK=-1 -DSQLITE_ENABLE_LOCKING_STYLE=1 -DSQLITE_OMIT_LOAD_EXTENSION=1 -DHAVE_READLINE=1 -I/opt/local/include/ -DSQLITE_ENABLE_LOCKING_STYLE=1 -lpthread  \
        -o sqlite3 ./src/shell.c libsqlite3.la \
        -L/opt/local/lib -lreadline 
/usr/bin/gcc-4.0 -g -O2 -I. -I./src -DNDEBUG -DTHREADSAFE=1 -DSQLITE_THREAD_OVERRIDE_LOCK=-1 -DSQLITE_ENABLE_LOCKING_STYLE=1 -DSQLITE_OMIT_LOAD_EXTENSION=1 -DHAVE_READLINE=1 -I/opt/local/include/ -DSQLITE_ENABLE_LOCKING_STYLE=1 -o .libs/sqlite3 ./src/shell.c  ./.libs/libsqlite3.dylib -lpthread -L/opt/local/lib -lreadline
/usr/bin/ld: warning prebinding disabled because dependent library: /opt/local/lib/libsqlite3.0.dylib is not prebound
/usr/bin/ld: warning can't open dynamic library: /opt/local/var/db/dports/build/_opt_local_var_db_dports_sources_rsync.rsync.macports.org_dpupdate_dports_devel_ncurses/work/destroot/opt/local/lib/libncurses.5.dylib referenced from: /opt/local/lib/libreadline.dylib (checking for undefined symbols may be affected) (No such file or directory, errno = 2)
/usr/bin/ld: Undefined symbols:
_tgetent referenced from libreadline expected to be defined in /opt/local/var/db/dports/build/_opt_local_var_db_dports_sources_rsync.rsync.macports.org_dpupdate_dports_devel_ncurses/work/destroot/opt/local/lib/libncurses.5.dylib
_tgetflag referenced from libreadline expected to be defined in /opt/local/var/db/dports/build/_opt_local_var_db_dports_sources_rsync.rsync.macports.org_dpupdate_dports_devel_ncurses/work/destroot/opt/local/lib/libncurses.5.dylib
_tgetnum referenced from libreadline expected to be defined in /opt/local/var/db/dports/build/_opt_local_var_db_dports_sources_rsync.rsync.macports.org_dpupdate_dports_devel_ncurses/work/destroot/opt/local/lib/libncurses.5.dylib
_tgetstr referenced from libreadline expected to be defined in /opt/local/var/db/dports/build/_opt_local_var_db_dports_sources_rsync.rsync.macports.org_dpupdate_dports_devel_ncurses/work/destroot/opt/local/lib/libncurses.5.dylib
_tputs referenced from libreadline expected to be defined in /opt/local/var/db/dports/build/_opt_local_var_db_dports_sources_rsync.rsync.macports.org_dpupdate_dports_devel_ncurses/work/destroot/opt/local/lib/libncurses.5.dylib
_tgoto referenced from libreadline expected to be defined in /opt/local/var/db/dports/build/_opt_local_var_db_dports_sources_rsync.rsync.macports.org_dpupdate_dports_devel_ncurses/work/destroot/opt/local/lib/libncurses.5.dylib
collect2: ld returned 1 exit status
gnumake: *** [sqlite3] Error 1

Error: Unable to upgrade port: 1

こんな感じ。readlineがおかしいのかな?と言うことで

$ sudo port upgrade -nf readline

をやると直った。