pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/math/R + Remove modifications to configure.in and conf...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/63a4cf5c4176
branches:  trunk
changeset: 539492:63a4cf5c4176
user:      jlam <jlam%pkgsrc.org@localhost>
date:      Fri Mar 07 16:11:39 2008 +0000

description:
+ Remove modifications to configure.in and configure in patch-aa and
  patch-ac that altered the order in which the terminal library for
  readline was detected.  The termcap.buildlink3.mk file (included
  indirectly by readline/buildlink3.mk) will do the right thing by
  itself.

+ Modify the pkg-index.tmpl INSTALL script fragment: we can just use
  ${PKG_PREFIX} instead of substituting for @PREFIX@ everywhere.  Also
  refactor the commands to rebuild the package index into a shell
  function and give some indication to the user what is happening.

+ Remove chown operation in post-install that was basically
  cargo-culted from the very first version of R imported into pkgsrc.
  It's not necessary.

+ Support user-destdir installation.

Bump the PKGREVISION to 2.

diffstat:

 math/R/Makefile             |    8 +-
 math/R/distinfo             |    6 +-
 math/R/files/pkg-index.tmpl |   30 ++++---
 math/R/patches/patch-aa     |   15 +----
 math/R/patches/patch-ac     |  150 +-------------------------------------------
 5 files changed, 25 insertions(+), 184 deletions(-)

diffs (284 lines):

diff -r 9abc1591a956 -r 63a4cf5c4176 math/R/Makefile
--- a/math/R/Makefile   Fri Mar 07 15:26:46 2008 +0000
+++ b/math/R/Makefile   Fri Mar 07 16:11:39 2008 +0000
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.94 2007/11/08 19:39:43 joerg Exp $
+# $NetBSD: Makefile,v 1.95 2008/03/07 16:11:39 jlam Exp $
 
 DISTNAME=              R-2.6.0
-PKGREVISION=           1
+PKGREVISION=           2
 CATEGORIES=            math
 MASTER_SITES=          ${MASTER_SITE_R_CRAN:=base/R-2/}
 
@@ -14,6 +14,7 @@
                        NetBSD-1.5.*-alpha NetBSD-1.5[A-U]-alpha
 
 PKG_INSTALLATION_TYPES=        overwrite pkgviews
+PKG_DESTDIR_SUPPORT=   user-destdir
 
 TEST_TARGET=           check
 USE_TOOLS+=            gmake gzip:run makeinfo perl:run sed unzip:run xmkmf
@@ -99,7 +100,4 @@
 PRINT_PLIST_AWK+=      /^lib\/R\/doc\/html\/packages.html$$/ { next; }
 PRINT_PLIST_AWK+=      /^lib\/R\/doc\/html\/search\/index.txt$$/ { next; }
 
-post-install:
-       ${CHOWN} -R ${SHAREOWN}:${SHAREGRP} ${PREFIX}/lib/R
-
 .include "../../mk/bsd.pkg.mk"
diff -r 9abc1591a956 -r 63a4cf5c4176 math/R/distinfo
--- a/math/R/distinfo   Fri Mar 07 15:26:46 2008 +0000
+++ b/math/R/distinfo   Fri Mar 07 16:11:39 2008 +0000
@@ -1,9 +1,9 @@
-$NetBSD: distinfo,v 1.35 2007/11/03 20:14:40 markd Exp $
+$NetBSD: distinfo,v 1.36 2008/03/07 16:11:39 jlam Exp $
 
 SHA1 (R-2.6.0.tar.gz) = ff51578fc630e65ce0e2bb92b0e1f8324c94925d
 RMD160 (R-2.6.0.tar.gz) = 54b3d183dfb15af7f861e7b62904998865ad194c
 Size (R-2.6.0.tar.gz) = 15447985 bytes
-SHA1 (patch-aa) = 50d7038e5933678646b0d48ea4f0d02959e6aebe
+SHA1 (patch-aa) = 0e1deea1411b5d1c31c9cc46708c08cc20d5c8c5
 SHA1 (patch-ab) = b724b549cd9920865c4d4ae60c71dff48c4c0c06
-SHA1 (patch-ac) = 4acc42574174a45e9ff8213fca2536ff4906bb80
+SHA1 (patch-ac) = 5c0013236b2effaabb381a2426565bd1f73f5d5e
 SHA1 (patch-ad) = 666dccbc9741b90bc7af11e51ccf25240906da8b
diff -r 9abc1591a956 -r 63a4cf5c4176 math/R/files/pkg-index.tmpl
--- a/math/R/files/pkg-index.tmpl       Fri Mar 07 15:26:46 2008 +0000
+++ b/math/R/files/pkg-index.tmpl       Fri Mar 07 16:11:39 2008 +0000
@@ -1,25 +1,29 @@
-# $NetBSD: pkg-index.tmpl,v 1.1 2007/03/14 11:50:34 markd Exp $
+# $NetBSD: pkg-index.tmpl,v 1.2 2008/03/07 16:11:39 jlam Exp $
+#
+# Rebuild R package indices upon installation or deinstallation of an
+# R extension.
 #
-# Rebuild R package indexes
-#
+
+rebuild_R_pkg_indices()
+{
+       ${ECHO} "${PKGNAME}: rebuilding R package indices and help files"
+       R CMD ${PERL5} ${PKG_PREFIX}/lib/R/share/perl/build-help.pl \
+               --htmllists 2>/dev/null
+       ${CAT} ${PKG_PREFIX}/lib/R/library/*/CONTENTS \
+               > ${PKG_PREFIX}/lib/R/doc/html/search/index.txt 2>/dev/null
+}
 
 case ${STAGE} in
 POST-INSTALL)
-       R CMD ${PERL5} @PREFIX@/lib/R/share/perl/build-help.pl --htmllists 2>/dev/null
-       ${CAT} @PREFIX@/lib/R/library/*/CONTENTS > @PREFIX@/lib/R/doc/html/search/index.txt 2>/dev/null
+       rebuild_R_pkg_indices
        ;;
 DEINSTALL)
        if [ "${PKGBASE}" = "R" ] ; then
-               ${RM} -f @PREFIX@/lib/R/doc/html/packages.html
-               ${RM} -f @PREFIX@/lib/R/doc/html/search/index.txt
+               ${RM} -f ${PKG_PREFIX}/lib/R/doc/html/packages.html
+               ${RM} -f ${PKG_PREFIX}/lib/R/doc/html/search/index.txt
        fi
        ;;
 POST-DEINSTALL)
-       if [ "${PKGBASE}" != "R" ] ; then
-               R CMD ${PERL5} @PREFIX@/lib/R/share/perl/build-help.pl --htmllists 2>/dev/null
-               ${CAT} @PREFIX@/lib/R/library/*/CONTENTS > @PREFIX@/lib/R/doc/html/search/index.txt 2>/dev/null
-       fi
-       ;;
-*)
+       [ "${PKGBASE}" = "R" ] || rebuild_R_pkg_indices
        ;;
 esac
diff -r 9abc1591a956 -r 63a4cf5c4176 math/R/patches/patch-aa
--- a/math/R/patches/patch-aa   Fri Mar 07 15:26:46 2008 +0000
+++ b/math/R/patches/patch-aa   Fri Mar 07 16:11:39 2008 +0000
@@ -1,4 +1,4 @@
-$NetBSD: patch-aa,v 1.18 2007/11/03 20:14:40 markd Exp $
+$NetBSD: patch-aa,v 1.19 2008/03/07 16:11:39 jlam Exp $
 
 --- configure.ac.orig  2007-09-21 14:05:04.000000000 +1200
 +++ configure.ac
@@ -11,19 +11,6 @@
  else
    LIBR=
  fi
-@@ -672,9 +672,9 @@ if test "${use_readline}" = yes; then
-   if test "${use_readline}" = no; then
-     ## only need ncurses if libreadline is not statically linked against it
-     unset ac_cv_lib_readline_rl_callback_read_char
--    AC_CHECK_LIB(ncurses, main, [],
--                 AC_CHECK_LIB(termcap, main, [],
--                              AC_CHECK_LIB(termlib, main)))
-+    AC_CHECK_LIB(termcap, main, [],
-+                 AC_CHECK_LIB(termlib, main, [],
-+                              AC_CHECK_LIB(ncurses, main)))
-     AC_CHECK_LIB(readline, rl_callback_read_char)
-     use_readline="${ac_cv_lib_readline_rl_callback_read_char}"
-   fi
 @@ -817,13 +817,6 @@ case "${host_cpu}" in
        R_PROG_CC_FLAG([-ieee_with_inexact],
                       R_SH_VAR_ADD(R_XTRA_CFLAGS, [-ieee_with_inexact]))
diff -r 9abc1591a956 -r 63a4cf5c4176 math/R/patches/patch-ac
--- a/math/R/patches/patch-ac   Fri Mar 07 15:26:46 2008 +0000
+++ b/math/R/patches/patch-ac   Fri Mar 07 16:11:39 2008 +0000
@@ -1,4 +1,4 @@
-$NetBSD: patch-ac,v 1.20 2007/11/03 20:14:40 markd Exp $
+$NetBSD: patch-ac,v 1.21 2008/03/07 16:11:39 jlam Exp $
 
 --- configure.orig     2007-09-26 14:06:08.000000000 +1200
 +++ configure
@@ -101,154 +101,6 @@
    objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
    version_type=freebsd-$objformat
    case $version_type in
-@@ -24329,13 +24329,13 @@ fi
-     ## only need ncurses if libreadline is not statically linked against it
-     unset ac_cv_lib_readline_rl_callback_read_char
- 
--{ echo "$as_me:$LINENO: checking for main in -lncurses" >&5
--echo $ECHO_N "checking for main in -lncurses... $ECHO_C" >&6; }
--if test "${ac_cv_lib_ncurses_main+set}" = set; then
-+{ echo "$as_me:$LINENO: checking for main in -ltermcap" >&5
-+echo $ECHO_N "checking for main in -ltermcap... $ECHO_C" >&6; }
-+if test "${ac_cv_lib_termcap_main+set}" = set; then
-   echo $ECHO_N "(cached) $ECHO_C" >&6
- else
-   ac_check_lib_save_LIBS=$LIBS
--LIBS="-lncurses  $LIBS"
-+LIBS="-ltermcap  $LIBS"
- cat >conftest.$ac_ext <<_ACEOF
- /* confdefs.h.  */
- _ACEOF
-@@ -24386,36 +24386,36 @@ eval "echo \"\$as_me:$LINENO: $ac_try_ec
-   ac_status=$?
-   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-   (exit $ac_status); }; }; then
--  ac_cv_lib_ncurses_main=yes
-+  ac_cv_lib_termcap_main=yes
- else
-   echo "$as_me: failed program was:" >&5
- sed 's/^/| /' conftest.$ac_ext >&5
- 
--      ac_cv_lib_ncurses_main=no
-+      ac_cv_lib_termcap_main=no
- fi
- 
- rm -f core conftest.err conftest.$ac_objext \
-       conftest$ac_exeext conftest.$ac_ext
- LIBS=$ac_check_lib_save_LIBS
- fi
--{ echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_main" >&5
--echo "${ECHO_T}$ac_cv_lib_ncurses_main" >&6; }
--if test $ac_cv_lib_ncurses_main = yes; then
-+{ echo "$as_me:$LINENO: result: $ac_cv_lib_termcap_main" >&5
-+echo "${ECHO_T}$ac_cv_lib_termcap_main" >&6; }
-+if test $ac_cv_lib_termcap_main = yes; then
-   cat >>confdefs.h <<_ACEOF
--#define HAVE_LIBNCURSES 1
-+#define HAVE_LIBTERMCAP 1
- _ACEOF
- 
--  LIBS="-lncurses $LIBS"
-+  LIBS="-ltermcap $LIBS"
- 
- else
- 
--{ echo "$as_me:$LINENO: checking for main in -ltermcap" >&5
--echo $ECHO_N "checking for main in -ltermcap... $ECHO_C" >&6; }
--if test "${ac_cv_lib_termcap_main+set}" = set; then
-+{ echo "$as_me:$LINENO: checking for main in -ltermlib" >&5
-+echo $ECHO_N "checking for main in -ltermlib... $ECHO_C" >&6; }
-+if test "${ac_cv_lib_termlib_main+set}" = set; then
-   echo $ECHO_N "(cached) $ECHO_C" >&6
- else
-   ac_check_lib_save_LIBS=$LIBS
--LIBS="-ltermcap  $LIBS"
-+LIBS="-ltermlib  $LIBS"
- cat >conftest.$ac_ext <<_ACEOF
- /* confdefs.h.  */
- _ACEOF
-@@ -24466,36 +24466,36 @@ eval "echo \"\$as_me:$LINENO: $ac_try_ec
-   ac_status=$?
-   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-   (exit $ac_status); }; }; then
--  ac_cv_lib_termcap_main=yes
-+  ac_cv_lib_termlib_main=yes
- else
-   echo "$as_me: failed program was:" >&5
- sed 's/^/| /' conftest.$ac_ext >&5
- 
--      ac_cv_lib_termcap_main=no
-+      ac_cv_lib_termlib_main=no
- fi
- 
- rm -f core conftest.err conftest.$ac_objext \
-       conftest$ac_exeext conftest.$ac_ext
- LIBS=$ac_check_lib_save_LIBS
- fi
--{ echo "$as_me:$LINENO: result: $ac_cv_lib_termcap_main" >&5
--echo "${ECHO_T}$ac_cv_lib_termcap_main" >&6; }
--if test $ac_cv_lib_termcap_main = yes; then
-+{ echo "$as_me:$LINENO: result: $ac_cv_lib_termlib_main" >&5
-+echo "${ECHO_T}$ac_cv_lib_termlib_main" >&6; }
-+if test $ac_cv_lib_termlib_main = yes; then
-   cat >>confdefs.h <<_ACEOF
--#define HAVE_LIBTERMCAP 1
-+#define HAVE_LIBTERMLIB 1
- _ACEOF
- 
--  LIBS="-ltermcap $LIBS"
-+  LIBS="-ltermlib $LIBS"
- 
- else
- 
--{ echo "$as_me:$LINENO: checking for main in -ltermlib" >&5
--echo $ECHO_N "checking for main in -ltermlib... $ECHO_C" >&6; }
--if test "${ac_cv_lib_termlib_main+set}" = set; then
-+{ echo "$as_me:$LINENO: checking for main in -lncurses" >&5
-+echo $ECHO_N "checking for main in -lncurses... $ECHO_C" >&6; }
-+if test "${ac_cv_lib_ncurses_main+set}" = set; then
-   echo $ECHO_N "(cached) $ECHO_C" >&6
- else
-   ac_check_lib_save_LIBS=$LIBS
--LIBS="-ltermlib  $LIBS"
-+LIBS="-lncurses  $LIBS"
- cat >conftest.$ac_ext <<_ACEOF
- /* confdefs.h.  */
- _ACEOF
-@@ -24546,26 +24546,26 @@ eval "echo \"\$as_me:$LINENO: $ac_try_ec
-   ac_status=$?
-   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-   (exit $ac_status); }; }; then
--  ac_cv_lib_termlib_main=yes
-+  ac_cv_lib_ncurses_main=yes
- else
-   echo "$as_me: failed program was:" >&5
- sed 's/^/| /' conftest.$ac_ext >&5
- 
--      ac_cv_lib_termlib_main=no
-+      ac_cv_lib_ncurses_main=no
- fi
- 
- rm -f core conftest.err conftest.$ac_objext \
-       conftest$ac_exeext conftest.$ac_ext
- LIBS=$ac_check_lib_save_LIBS
- fi
--{ echo "$as_me:$LINENO: result: $ac_cv_lib_termlib_main" >&5
--echo "${ECHO_T}$ac_cv_lib_termlib_main" >&6; }
--if test $ac_cv_lib_termlib_main = yes; then
-+{ echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_main" >&5
-+echo "${ECHO_T}$ac_cv_lib_ncurses_main" >&6; }
-+if test $ac_cv_lib_ncurses_main = yes; then
-   cat >>confdefs.h <<_ACEOF
--#define HAVE_LIBTERMLIB 1
-+#define HAVE_LIBNCURSES 1
- _ACEOF
- 
--  LIBS="-ltermlib $LIBS"
-+  LIBS="-lncurses $LIBS"
- 
- fi
- 
 @@ -32398,6 +32398,7 @@ cat > conftest.c <<EOF
  #else
  # define F77_SYMBOL(x)   x



Home | Main Index | Thread Index | Old Index