pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/databases Use subst.mk instead of using sed(1)/mv(1)/r...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/ab24b5928f3a
branches:  trunk
changeset: 482427:ab24b5928f3a
user:      xtraeme <xtraeme%pkgsrc.org@localhost>
date:      Thu Oct 28 01:34:27 2004 +0000

description:
Use subst.mk instead of using sed(1)/mv(1)/rm(1).

diffstat:

 databases/mysql-client/Makefile.common  |  27 ++++++++++++---------------
 databases/mysql4-client/Makefile.common |  27 ++++++++++++---------------
 2 files changed, 24 insertions(+), 30 deletions(-)

diffs (82 lines):

diff -r e5001520bdee -r ab24b5928f3a databases/mysql-client/Makefile.common
--- a/databases/mysql-client/Makefile.common    Thu Oct 28 01:22:30 2004 +0000
+++ b/databases/mysql-client/Makefile.common    Thu Oct 28 01:34:27 2004 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.common,v 1.26 2004/10/28 01:08:15 xtraeme Exp $
+# $NetBSD: Makefile.common,v 1.27 2004/10/28 01:34:27 xtraeme Exp $
 
 DISTNAME=              mysql-4.0.21
 CATEGORIES=            databases
@@ -71,20 +71,17 @@
 USE_LIBTOOL=           # defined
 LDFLAGS+=              ${COMPILER_RPATH_FLAG}${PREFIX}/lib/mysql
 
-post-extract:
-       cd ${WRKSRC};                                                   \
-       for dir in dbug heap isam merge mysys strings; do               \
-               ${MV} $${dir}/Makefile.in $${dir}/Makefile.in.orig;     \
-               ${SED} -e "/^install-exec:/s/install-pkglibLIBRARIES//" \
-                       $${dir}/Makefile.in.orig > $${dir}/Makefile.in; \
-       done
-       cd ${WRKSRC}/scripts;                                           \
-       for file in mysql_install_db.sh mysqld_safe.sh; do              \
-               ${MV} $${file} $${file}.orig;                           \
-               ${SED} -e "s,chown,${CHOWN},g"                          \
-                       $${file}.orig > $${file};                       \
-               ${RM} $${file}.orig;                                    \
-       done
+SUBST_CLASSES+=                mk scripts
+SUBST_STAGE.mk=                post-extract
+SUBST_FILES.mk=                dbug/Makefile.in heap/Makefile.in isam/Makefile.in \
+                       merge/Makefile.in mysys/Makefile.in \
+                       strings/Makefile.in
+SUBST_SED.mk=          -e "/^install-exec:/s/install-pkglibLIBRARIES//"
+SUBST_MESSAGE.mk=      "Fixing Makefiles."
+SUBST_STAGE.scripts=   post-extract
+SUBST_FILES.scripts=   scripts/mysql_install_db.sh scripts/mysqld_safe.sh
+SUBST_SED.scripts=     -e "s,chown,${CHOWN},g"
+SUBST_MESSAGE.scripts= "Fixing scripts."
 
 .include "../../security/openssl/buildlink3.mk"
 .include "../../devel/zlib/buildlink3.mk"
diff -r e5001520bdee -r ab24b5928f3a databases/mysql4-client/Makefile.common
--- a/databases/mysql4-client/Makefile.common   Thu Oct 28 01:22:30 2004 +0000
+++ b/databases/mysql4-client/Makefile.common   Thu Oct 28 01:34:27 2004 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.common,v 1.15 2004/10/28 01:12:44 xtraeme Exp $
+# $NetBSD: Makefile.common,v 1.16 2004/10/28 01:34:27 xtraeme Exp $
 
 DISTNAME=              mysql-4.1.7
 CATEGORIES=            databases
@@ -71,20 +71,17 @@
 USE_LIBTOOL=           # defined
 LDFLAGS+=              ${COMPILER_RPATH_FLAG}${PREFIX}/lib/mysql
 
-post-extract:
-       cd ${WRKSRC};                                                   \
-       for dir in dbug heap isam merge mysys strings; do               \
-               ${MV} $${dir}/Makefile.in $${dir}/Makefile.in.orig;     \
-               ${SED} -e "/^install-exec:/s/install-pkglibLIBRARIES//" \
-                       $${dir}/Makefile.in.orig > $${dir}/Makefile.in; \
-       done
-       cd ${WRKSRC}/scripts;                                           \
-       for file in mysql_install_db.sh mysqld_safe.sh; do              \
-               ${MV} $${file} $${file}.orig;                           \
-               ${SED} -e "s,chown,${CHOWN},g"                          \
-                       $${file}.orig > $${file};                       \
-               ${RM} $${file}.orig;                                    \
-       done
+SUBST_CLASSES+=                mk scripts
+SUBST_STAGE.mk=                post-extract
+SUBST_FILES.mk=                dbug/Makefile.in heap/Makefile.in isam/Makefile.in \
+                       merge/Makefile.in mysys/Makefile.in \
+                       strings/Makefile.in
+SUBST_SED.mk=          -e "/^install-exec:/s/install-pkglibLIBRARIES//"
+SUBST_MESSAGE.mk=      "Fixing Makefiles."
+SUBST_STAGE.scripts=   post-extract
+SUBST_FILES.scripts=   scripts/mysql_install_db.sh scripts/mysqld_safe.sh      
+SUBST_SED.scripts=     -e "s,chown,${CHOWN},g"
+SUBST_MESSAGE.scripts= "Fixing scripts."
 
 .include "../../security/openssl/buildlink3.mk"
 .include "../../devel/zlib/buildlink3.mk"



Home | Main Index | Thread Index | Old Index