diff options
Diffstat (limited to 'app-editors/nvi/files/nvi-1.81.5-db4.patch')
-rw-r--r-- | app-editors/nvi/files/nvi-1.81.5-db4.patch | 134 |
1 files changed, 134 insertions, 0 deletions
diff --git a/app-editors/nvi/files/nvi-1.81.5-db4.patch b/app-editors/nvi/files/nvi-1.81.5-db4.patch index 38248b6eed39..d6191cb501f2 100644 --- a/app-editors/nvi/files/nvi-1.81.5-db4.patch +++ b/app-editors/nvi/files/nvi-1.81.5-db4.patch @@ -1,3 +1,137 @@ +--- nvi-1.81.5/dist/configure.in ++++ nvi-1.81.5/dist/configure.in +@@ -922,11 +922,14 @@ + CFLAGS="-I$with_db3/include $CFLAGS" + fi; + ++saveLIBS="$LIBS" ++LIBS="$LIBS -ldb" +-AC_CHECK_LIB(db, db_create, ++AC_TRY_LINK([#include <db.h>], [db_create(0, 0, 0)], + [vi_cv_dbfatal="no"], [vi_cv_dbfatal="yes"]) + if test "$vi_cv_dbfatal" = "yes"; then +- AC_MSG_ERROR([Need DB 3.]) ++ AC_MSG_ERROR([Need DB 4.]) + fi ++LIBS="$saveLIBS" + + LDFLAGS="$saveLDFLAGS" + +--- nvi-1.81.5/dist/configure ++++ nvi-1.81.5/dist/configure +@@ -10679,56 +10679,36 @@ + CFLAGS="-I$with_db3/include $CFLAGS" + fi; + +-echo $ac_n "checking for db_create in -ldb""... $ac_c" 1>&6 +-echo "configure:10684: checking for db_create in -ldb" >&5 +-ac_lib_var=`echo db'_'db_create | sed 'y%./+-%__p_%'` +-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +- echo $ac_n "(cached) $ac_c" 1>&6 +-else +- ac_save_LIBS="$LIBS" +-LIBS="-ldb $LIBS" ++saveLIBS="$LIBS" ++LIBS="$LIBS -ldb" + cat > conftest.$ac_ext <<EOF +-#line 10692 "configure" ++#line 10686 "configure" + #include "confdefs.h" +-/* Override any gcc2 internal prototype to avoid an error. */ +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char db_create(); +- ++#include <db.h> + int main() { +-db_create() ++db_create(0, 0, 0) + ; return 0; } + EOF +-if { (eval echo configure:10703: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:10693: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* +- eval "ac_cv_lib_$ac_lib_var=yes" ++ vi_cv_dbfatal="no" + else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* +- eval "ac_cv_lib_$ac_lib_var=no" ++ vi_cv_dbfatal="yes" + fi + rm -f conftest* +-LIBS="$ac_save_LIBS" +- +-fi +-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then +- echo "$ac_t""yes" 1>&6 +- vi_cv_dbfatal="no" +-else +- echo "$ac_t""no" 1>&6 +-vi_cv_dbfatal="yes" +-fi +- + if test "$vi_cv_dbfatal" = "yes"; then +- { echo "configure: error: Need DB 3." 1>&2; exit 1; } ++ { echo "configure: error: Need DB 4." 1>&2; exit 1; } + fi ++LIBS="$saveLIBS" + + LDFLAGS="$saveLDFLAGS" + + + echo $ac_n "checking if --enable-dynamic-loading option specified""... $ac_c" 1>&6 +-echo "configure:10732: checking if --enable-dynamic-loading option specified" >&5 ++echo "configure:10712: checking if --enable-dynamic-loading option specified" >&5 + # Check whether --enable-dynamic-loading or --disable-dynamic-loading was given. + if test "${enable_dynamic_loading+set}" = set; then + enableval="$enable_dynamic_loading" +@@ -10740,7 +10720,7 @@ + echo "$ac_t""$vi_cv_dl" 1>&6 + if test "$vi_cv_dl" = yes; then + echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 +-echo "configure:10744: checking for dlopen in -ldl" >&5 ++echo "configure:10724: checking for dlopen in -ldl" >&5 + ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` + if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +@@ -10748,7 +10728,7 @@ + ac_save_LIBS="$LIBS" + LIBS="-ldl $LIBS" + cat > conftest.$ac_ext <<EOF +-#line 10752 "configure" ++#line 10732 "configure" + #include "confdefs.h" + /* Override any gcc2 internal prototype to avoid an error. */ + /* We use char because int might match the return type of a gcc2 +@@ -10759,7 +10739,7 @@ + dlopen() + ; return 0; } + EOF +-if { (eval echo configure:10763: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:10743: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" + else +@@ -10789,7 +10769,7 @@ + # Extract the first word of "libdb-3.so", so it can be a program name with args. + set dummy libdb-3.so; ac_word=$2 + echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +-echo "configure:10793: checking for $ac_word" >&5 ++echo "configure:10773: checking for $ac_word" >&5 + if eval "test \"`echo '$''{'ac_cv_path_vi_cv_path_db3'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else +@@ -10843,7 +10823,7 @@ + + + echo $ac_n "checking if --disable-re option specified""... $ac_c" 1>&6 +-echo "configure:10847: checking if --disable-re option specified" >&5 ++echo "configure:10827: checking if --disable-re option specified" >&5 + # Check whether --enable-re or --disable-re was given. + if test "${enable_re+set}" = set; then + enableval="$enable_re" --- nvi-1.81.5/common/exf.c +++ nvi-1.81.5/common/exf.c @@ -282,7 +282,7 @@ |