[PATCH] A small bug fixed in --with-python patch

There were a few scripts nestled among all the ones I converted to use #! /usr/bin/env @PYTHON@ that were not being installed, because they did not have a #! line at all. Here's a version of the patch that fixes this error by removing these scripts from the SCRIPTS variable in the various Makefile.in files and moving them to a NONSCRIPTS variable, which tells a make install to look for scripts/foo instead of build/scripts/foo . (Since these files are not executable and are not meant to be executable, they're not really scripts, but I'm not sure what they are. :) This patch is against current Mailman CVS. Ben diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/Makefile.in mailman/Makefile.in --- mailman.cvs.orig/Makefile.in Thu Sep 6 11:51:15 2001 +++ mailman/Makefile.in Thu Sep 6 11:57:24 2001 @@ -140,6 +140,7 @@ (cd $$d; $(MAKE) distclean); \ done -rm -f config.cache config.log config.status Makefile + -rm -rf build langpack: tar zcvf langpack-$(DATE).tgz $(EXCLUDES) $(LANGPACK) diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/Makefile.in mailman/bin/Makefile.in --- mailman.cvs.orig/bin/Makefile.in Tue Aug 21 05:08:41 2001 +++ mailman/bin/Makefile.in Thu Sep 6 12:05:33 2001 @@ -44,9 +44,13 @@ SCRIPTS= digest_arch mmsitepass newlist rmlist add_members \ list_members remove_members clone_member update arch \ sync_members check_db withlist check_perms find_member \ - version config_list list_lists dumpdb fix_url.py \ + version config_list list_lists dumpdb \ list_admins genaliases change_pw mailmanctl qrunner +NONSCRIPTS= fix_url.py + +BUILDDIR= ../build/bin + # Modes for directories and executables created by the install # process. Default to group-writable directories but # user-only-writable for executables. @@ -63,7 +67,12 @@ install: for f in $(SCRIPTS); \ do \ - $(INSTALL) -m $(EXEMODE) $$f $(SCRIPTSDIR); \ + $(INSTALL) -m $(EXEMODE) $(BUILDDIR)/$$f $(SCRIPTSDIR); \ + done + + for f in $(NONSCRIPTS); \ + do \ + $(INSTALL) -m $(FILEMODE) $$f $(SCRIPTSDIR); \ done finish: diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/add_members mailman/bin/add_members --- mailman.cvs.orig/bin/add_members Sat Aug 4 11:05:41 2001 +++ mailman/bin/add_members Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/arch mailman/bin/arch --- mailman.cvs.orig/bin/arch Thu Jul 26 14:30:28 2001 +++ mailman/bin/arch Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/change_pw mailman/bin/change_pw --- mailman.cvs.orig/bin/change_pw Sat Aug 4 11:05:41 2001 +++ mailman/bin/change_pw Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/check_db mailman/bin/check_db --- mailman.cvs.orig/bin/check_db Fri Dec 8 04:33:52 2000 +++ mailman/bin/check_db Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/check_perms mailman/bin/check_perms --- mailman.cvs.orig/bin/check_perms Mon Jul 2 22:55:23 2001 +++ mailman/bin/check_perms Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/clone_member mailman/bin/clone_member --- mailman.cvs.orig/bin/clone_member Mon Jul 30 06:26:49 2001 +++ mailman/bin/clone_member Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/config_list mailman/bin/config_list --- mailman.cvs.orig/bin/config_list Sat May 26 00:18:34 2001 +++ mailman/bin/config_list Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/digest_arch mailman/bin/digest_arch --- mailman.cvs.orig/bin/digest_arch Mon Mar 26 09:03:46 2001 +++ mailman/bin/digest_arch Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/dumpdb mailman/bin/dumpdb --- mailman.cvs.orig/bin/dumpdb Thu Jul 12 05:11:24 2001 +++ mailman/bin/dumpdb Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/find_member mailman/bin/find_member --- mailman.cvs.orig/bin/find_member Thu Jul 19 12:28:20 2001 +++ mailman/bin/find_member Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/genaliases mailman/bin/genaliases --- mailman.cvs.orig/bin/genaliases Wed Sep 5 12:04:45 2001 +++ mailman/bin/genaliases Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/list_admins mailman/bin/list_admins --- mailman.cvs.orig/bin/list_admins Thu Mar 22 12:42:00 2001 +++ mailman/bin/list_admins Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/list_lists mailman/bin/list_lists --- mailman.cvs.orig/bin/list_lists Fri Dec 8 04:33:52 2000 +++ mailman/bin/list_lists Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/list_members mailman/bin/list_members --- mailman.cvs.orig/bin/list_members Thu Jul 19 12:28:20 2001 +++ mailman/bin/list_members Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/mailmanctl mailman/bin/mailmanctl --- mailman.cvs.orig/bin/mailmanctl Thu Aug 16 04:38:00 2001 +++ mailman/bin/mailmanctl Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # Copyright (C) 2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/mmsitepass mailman/bin/mmsitepass --- mailman.cvs.orig/bin/mmsitepass Fri Jun 1 01:15:05 2001 +++ mailman/bin/mmsitepass Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/newlist mailman/bin/newlist --- mailman.cvs.orig/bin/newlist Tue Aug 21 00:15:56 2001 +++ mailman/bin/newlist Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/pygettext.py mailman/bin/pygettext.py --- mailman.cvs.orig/bin/pygettext.py Sat Jul 28 02:22:55 2001 +++ mailman/bin/pygettext.py Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # Originally written by Barry Warsaw <barry@zope.com> # # Minimally patched to make it even more xgettext compatible diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/qrunner mailman/bin/qrunner --- mailman.cvs.orig/bin/qrunner Fri Jul 6 06:58:21 2001 +++ mailman/bin/qrunner Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # Copyright (C) 2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/remove_members mailman/bin/remove_members --- mailman.cvs.orig/bin/remove_members Fri Jul 20 05:01:48 2001 +++ mailman/bin/remove_members Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/rmlist mailman/bin/rmlist --- mailman.cvs.orig/bin/rmlist Thu May 10 00:04:15 2001 +++ mailman/bin/rmlist Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/sync_members mailman/bin/sync_members --- mailman.cvs.orig/bin/sync_members Thu Jul 19 12:28:20 2001 +++ mailman/bin/sync_members Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/update mailman/bin/update --- mailman.cvs.orig/bin/update Thu Aug 16 06:30:26 2001 +++ mailman/bin/update Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/version mailman/bin/version --- mailman.cvs.orig/bin/version Fri Dec 8 04:33:52 2000 +++ mailman/bin/version Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/bin/withlist mailman/bin/withlist --- mailman.cvs.orig/bin/withlist Wed Aug 1 15:30:33 2001 +++ mailman/bin/withlist Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/configure mailman/configure --- mailman.cvs.orig/configure Sat Aug 18 08:20:12 2001 +++ mailman/configure Thu Sep 6 12:09:01 2001 @@ -1,6 +1,6 @@ #! /bin/sh -# From configure.in Revision: 2.11 +# From configure.in Revision: 2.12 # Guess values for system-dependent variables and create Makefiles. # Generated automatically using autoconf version 2.13 @@ -1980,6 +1980,59 @@ done + + + + + +SCRIPTS="build/contrib/rotatelogs.py:contrib/rotatelogs.py \ +build/contrib/qmail-to-mailman.py:contrib/qmail-to-mailman.py \ +build/contrib/securelinux_fix.py:contrib/securelinux_fix.py \ +build/filters/bowa-strip:filters/bowa-strip \ +build/cron/senddigests:cron/senddigests \ +build/cron/bumpdigests:cron/bumpdigests \ +build/cron/nightly_gzip:cron/nightly_gzip \ +build/cron/mailpasswds:cron/mailpasswds \ +build/cron/gate_news:cron/gate_news \ +build/cron/checkdbs:cron/checkdbs \ +build/bin/update:bin/update \ +build/bin/newlist:bin/newlist \ +build/bin/check_perms:bin/check_perms \ +build/bin/find_member:bin/find_member \ +build/bin/withlist:bin/withlist \ +build/bin/mailmanctl:bin/mailmanctl \ +build/bin/change_pw:bin/change_pw \ +build/bin/list_admins:bin/list_admins \ +build/bin/check_db:bin/check_db \ +build/bin/list_lists:bin/list_lists \ +build/bin/pygettext.py:bin/pygettext.py \ +build/bin/qrunner:bin/qrunner \ +build/bin/clone_member:bin/clone_member \ +build/bin/genaliases:bin/genaliases \ +build/bin/digest_arch:bin/digest_arch \ +build/bin/arch:bin/arch \ +build/bin/rmlist:bin/rmlist \ +build/bin/mmsitepass:bin/mmsitepass \ +build/bin/version:bin/version \ +build/bin/remove_members:bin/remove_members \ +build/bin/config_list:bin/config_list \ +build/bin/list_members:bin/list_members \ +build/bin/sync_members:bin/sync_members \ +build/bin/add_members:bin/add_members \ +build/bin/dumpdb:bin/dumpdb \ +build/scripts/mailowner:scripts/mailowner \ +build/scripts/mailcmd:scripts/mailcmd \ +build/scripts/post:scripts/post \ +build/scripts/leave:scripts/leave \ +build/scripts/join:scripts/join \ +build/scripts/auto:scripts/auto " + + + +# These directories are temporary directories to store macro-expanded +# scripts. They're removed on a make distclean, so we make them here. +mkdir -p build/bin build/scripts build/contrib build/filters build/cron + trap '' 1 2 15 cat > confcache <<\EOF # This file is a shell script that caches the results of configure @@ -2101,7 +2154,8 @@ Mailman/Queue/Makefile Mailman/MTA/Makefile Mailman/Gui/Makefile templates/Makefile cron/Makefile filters/Makefile scripts/Makefile messages/Makefile - cron/crontab.in misc/mailman Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 + cron/crontab.in misc/mailman Makefile + $SCRIPTS" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 EOF cat >> $CONFIG_STATUS <<EOF @@ -2151,6 +2205,7 @@ s%@FQDN@%$FQDN%g s%@URL@%$URL%g s%@CPP@%$CPP%g +s%@SCRIPTS@%$SCRIPTS%g CEOF EOF @@ -2200,7 +2255,8 @@ Mailman/Queue/Makefile Mailman/MTA/Makefile Mailman/Gui/Makefile templates/Makefile cron/Makefile filters/Makefile scripts/Makefile messages/Makefile - cron/crontab.in misc/mailman Makefile"} + cron/crontab.in misc/mailman Makefile + $SCRIPTS"} EOF cat >> $CONFIG_STATUS <<\EOF for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then @@ -2271,3 +2327,6 @@ rm -fr confdefs* $ac_clean_files test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 + +# Make sure all the build scripts are executable. +chmod -R +x build diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/configure.in mailman/configure.in --- mailman.cvs.orig/configure.in Sat Aug 18 08:20:12 2001 +++ mailman/configure.in Thu Sep 6 12:08:58 2001 @@ -470,6 +470,70 @@ # Checks for library functions. AC_CHECK_FUNCS(vsnprintf) +dnl Expand PYTHON path in the scripts, output into build/scriptname + +AC_DEFUN(MM_SCRIPTS, [dnl +contrib/rotatelogs.py \ +contrib/qmail-to-mailman.py \ +contrib/securelinux_fix.py \ +filters/bowa-strip \ +cron/senddigests \ +cron/bumpdigests \ +cron/nightly_gzip \ +cron/mailpasswds \ +cron/gate_news \ +cron/checkdbs \ +bin/update \ +bin/newlist \ +bin/check_perms \ +bin/find_member \ +bin/withlist \ +bin/mailmanctl \ +bin/change_pw \ +bin/list_admins \ +bin/check_db \ +bin/list_lists \ +bin/pygettext.py \ +bin/qrunner \ +bin/clone_member \ +bin/genaliases \ +bin/digest_arch \ +bin/arch \ +bin/rmlist \ +bin/mmsitepass \ +bin/version \ +bin/remove_members \ +bin/config_list \ +bin/list_members \ +bin/sync_members \ +bin/add_members \ +bin/dumpdb \ +scripts/mailowner \ +scripts/mailcmd \ +scripts/post \ +scripts/leave \ +scripts/join \ +scripts/auto ]) + +dnl Please make sure to leave a space at the end of the last entry. +dnl (This is so we don't have to use [a-z/] style character classes +dnl in the regexp below and mess with m4 quoting, which is not fun.) + +dnl This regexp munges each line in MM_SCRIPTS, replacing: +dnl path/script \ +dnl with: +dnl build/path/script:path/script \ +dnl so that we can macro-expand variables in scripts without using +dnl script.in filenames, outputting the new files in build/ . + +SCRIPTS="patsubst(MM_SCRIPTS, \(.+\) \(\\?\), build/\1:\1 \2)" + +AC_SUBST(SCRIPTS) + +# These directories are temporary directories to store macro-expanded +# scripts. They're removed on a make distclean, so we make them here. +mkdir -p build/bin build/scripts build/contrib build/filters build/cron + dnl Output everything AC_OUTPUT([misc/paths.py Mailman/Defaults.py Mailman/mm_cfg.py.dist src/Makefile misc/Makefile bin/Makefile @@ -479,4 +543,8 @@ Mailman/Queue/Makefile Mailman/MTA/Makefile Mailman/Gui/Makefile templates/Makefile cron/Makefile filters/Makefile scripts/Makefile messages/Makefile - cron/crontab.in misc/mailman Makefile]) + cron/crontab.in misc/mailman Makefile + $SCRIPTS]) + +# Make sure all the build scripts are executable. +chmod -R +x build diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/contrib/qmail-to-mailman.py mailman/contrib/qmail-to-mailman.py --- mailman.cvs.orig/contrib/qmail-to-mailman.py Fri Dec 8 01:53:21 2000 +++ mailman/contrib/qmail-to-mailman.py Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # Configuration variables - Change these for your site if necessary. MailmanHome = "/home/mailman"; # Mailman home directory. diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/contrib/rotatelogs.py mailman/contrib/rotatelogs.py --- mailman.cvs.orig/contrib/rotatelogs.py Sat Aug 4 11:06:06 2001 +++ mailman/contrib/rotatelogs.py Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 2000 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/contrib/securelinux_fix.py mailman/contrib/securelinux_fix.py --- mailman.cvs.orig/contrib/securelinux_fix.py Mon Mar 19 01:52:48 2001 +++ mailman/contrib/securelinux_fix.py Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/cron/Makefile.in mailman/cron/Makefile.in --- mailman.cvs.orig/cron/Makefile.in Sat Aug 4 11:06:50 2001 +++ mailman/cron/Makefile.in Thu Sep 6 11:57:03 2001 @@ -44,6 +44,8 @@ nightly_gzip bumpdigests FILES= crontab.in +BUILDDIR= ../build/cron + # Modes for directories and executables created by the install # process. Default to group-writable directories but # user-only-writable for executables. @@ -62,7 +64,7 @@ done for f in $(PROGRAMS); \ do \ - $(INSTALL) -m $(EXEMODE) $$f $(CRONDIR); \ + $(INSTALL) -m $(EXEMODE) $(BUILDDIR)/$$f $(CRONDIR); \ done finish: diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/cron/bumpdigests mailman/cron/bumpdigests --- mailman.cvs.orig/cron/bumpdigests Sat Jul 28 01:35:45 2001 +++ mailman/cron/bumpdigests Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/cron/checkdbs mailman/cron/checkdbs --- mailman.cvs.orig/cron/checkdbs Sat Jul 28 01:35:45 2001 +++ mailman/cron/checkdbs Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/cron/gate_news mailman/cron/gate_news --- mailman.cvs.orig/cron/gate_news Sat Jul 28 01:35:45 2001 +++ mailman/cron/gate_news Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/cron/mailpasswds mailman/cron/mailpasswds --- mailman.cvs.orig/cron/mailpasswds Sat Aug 4 14:23:56 2001 +++ mailman/cron/mailpasswds Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/cron/nightly_gzip mailman/cron/nightly_gzip --- mailman.cvs.orig/cron/nightly_gzip Sat Jul 28 01:35:45 2001 +++ mailman/cron/nightly_gzip Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/cron/senddigests mailman/cron/senddigests --- mailman.cvs.orig/cron/senddigests Sat Jul 28 01:35:45 2001 +++ mailman/cron/senddigests Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/filters/Makefile.in mailman/filters/Makefile.in --- mailman.cvs.orig/filters/Makefile.in Fri Dec 8 01:53:22 2000 +++ mailman/filters/Makefile.in Thu Sep 6 11:57:03 2001 @@ -43,6 +43,8 @@ FILTERS= bowa-strip +BUILDDIR= ../build/filters + # Modes for directories and executables created by the install # process. Default to group-writable directories but # user-only-writable for executables. @@ -59,7 +61,7 @@ install: for f in $(FILTERS); \ do \ - $(INSTALL) -m $(FILEMODE) $$f $(FILTERSDIR); \ + $(INSTALL) -m $(FILEMODE) $(BUILDDIR)/$$f $(FILTERSDIR); \ done finish: diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/filters/bowa-strip mailman/filters/bowa-strip --- mailman.cvs.orig/filters/bowa-strip Fri Dec 8 01:53:22 2000 +++ mailman/filters/bowa-strip Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/messages/Makefile.in mailman/messages/Makefile.in --- mailman.cvs.orig/messages/Makefile.in Sat Aug 18 06:24:01 2001 +++ mailman/messages/Makefile.in Thu Sep 6 11:57:03 2001 @@ -62,7 +62,7 @@ EXEMODE= 755 FILEMODE= 644 INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE) -PROG= bin/pygettext.py +PROG= build/bin/pygettext.py .SUFFIXES: .po .mo .po.mo: @@ -117,7 +117,7 @@ docstring.files: @echo "Calculating script input files for pygettext" - (cd ..; grep -d skip -l '^#! /usr/bin/env python' `find bin cron scripts -name ".#*" -prune -o -print` >| messages/$@) + (cd ..; grep -d skip -l '^#! /usr/bin/env @PYTHON@' `find bin cron scripts -name ".#*" -prune -o -print` >| messages/$@) mailman.pot: marked.files docstring.files @echo "Running pygettext on $@; this make take a while." diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/scripts/Makefile.in mailman/scripts/Makefile.in --- mailman.cvs.orig/scripts/Makefile.in Sat Aug 4 11:26:54 2001 +++ mailman/scripts/Makefile.in Thu Sep 6 12:04:10 2001 @@ -40,7 +40,10 @@ SHELL= /bin/sh -SCRIPTS= mailcmd mailowner post driver join leave +SCRIPTS= mailcmd mailowner post join leave +NONSCRIPTS= driver + +BUILDDIR= ../build/scripts # Modes for directories and executables created by the install # process. Default to group-writable directories but @@ -57,6 +60,11 @@ install: for f in $(SCRIPTS); \ + do \ + $(INSTALL) -m $(FILEMODE) $(BUILDDIR)/$$f $(SCRIPTSDIR); \ + done + + for f in $(NONSCRIPTS); \ do \ $(INSTALL) -m $(FILEMODE) $$f $(SCRIPTSDIR); \ done diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/scripts/auto mailman/scripts/auto --- mailman.cvs.orig/scripts/auto Thu Jun 28 08:00:47 2001 +++ mailman/scripts/auto Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/scripts/join mailman/scripts/join --- mailman.cvs.orig/scripts/join Thu Jun 28 08:01:22 2001 +++ mailman/scripts/join Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/scripts/leave mailman/scripts/leave --- mailman.cvs.orig/scripts/leave Thu Jun 28 08:01:42 2001 +++ mailman/scripts/leave Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/scripts/mailcmd mailman/scripts/mailcmd --- mailman.cvs.orig/scripts/mailcmd Thu Jun 28 08:02:03 2001 +++ mailman/scripts/mailcmd Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/scripts/mailowner mailman/scripts/mailowner --- mailman.cvs.orig/scripts/mailowner Thu Jun 28 08:02:29 2001 +++ mailman/scripts/mailowner Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. # diff -x CVS -x *.mo -x *.po -x *.pot -ruN mailman.cvs.orig/scripts/post mailman/scripts/post --- mailman.cvs.orig/scripts/post Thu Jun 28 08:02:46 2001 +++ mailman/scripts/post Thu Sep 6 11:57:03 2001 @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#! /usr/bin/env @PYTHON@ # # Copyright (C) 1998,1999,2000,2001 by the Free Software Foundation, Inc. #

"BG" == Ben Gertzfield <che@debian.org> writes:
BG> There were a few scripts nestled among all the ones I
BG> converted to use #! /usr/bin/env @PYTHON@ that were not being
BG> installed, because they did not have a #! line at all.
A couple of nits...
First, since your patch changes things so that the scripts no longer search for `python' on your $PATH, we don't need the /usr/bin/env trick anymore. So I think those lines can safely be changed to
#! @PYTHON@
No need to generate another patch Ben, I've made this change myself.
Second, we can forget about the filter directory; it's old, obsolete, and soon to be removed <wink>. Third, we don't need #! lines in the scripts/* files, since these will always be executed by the wrappers, which already have @PYTHON@ hard-coded into them. I've changed these lines to
#! -*- python -*-
to keep the Emacs major mode dance working.
Other than that, I think your patch looks fine. It certainly meets my requirements, seems to work, and solves your problem.
Unless I hear any objections, I'll go ahead and accept these changes.
Thanks Ben! -Barry

"BAW" == Barry A Warsaw <barry@zope.com> writes:
BAW> A couple of nits...
BAW> First, since your patch changes things so that the scripts no
BAW> longer search for `python' on your $PATH, we don't need the
BAW> /usr/bin/env trick anymore. So I think those lines can
BAW> safely be changed to
BAW> #! @PYTHON@
BAW> No need to generate another patch Ben, I've made this change
BAW> myself.
Great! That makes a lot of sense, I should have realized that. :)
BAW> Second, we can forget about the filter directory; it's old,
BAW> obsolete, and soon to be removed <wink>. Third, we don't
BAW> need #! lines in the scripts/* files, since these will always
BAW> be executed by the wrappers, which already have @PYTHON@
BAW> hard-coded into them. I've changed these lines to
Ah, okay. It's sometimes a little hard to be aware of the big picture, but that'll work great.
BAW> #! -*- python -*-
BAW> to keep the Emacs major mode dance working.
For future reference, you could also set it at the end of the file:
# Local-variables: # major-mode:python # End:
or something like that. :)
BAW> Other than that, I think your patch looks fine. It certainly
BAW> meets my requirements, seems to work, and solves your
BAW> problem.
BAW> Unless I hear any objections, I'll go ahead and accept these
BAW> changes.
Excellent! I'm really enjoying working with Mailman. Python is just so clean and easy to follow, it makes my life easy. :)
Thanks for helping solve the (future) Debian users' problems.
Ben
-- Brought to you by the letters A and B and the number 11. "Ohhhh, Mentos Boy!" Debian GNU/Linux maintainer of Gimp and GTK+ -- http://www.debian.org/

"BG" == Ben Gertzfield <che@debian.org> writes:
BAW> #! -*- python -*-
BAW> to keep the Emacs major mode dance working.
BG> For future reference, you could also set it at the end of the
BG> file:
| # Local-variables:
| # major-mode:python
| # End:
BG> or something like that. :)
Yeah, but I usually avoid Local-variables: sections for major mode settings. Force of habit I guess. ;)
BAW> Other than that, I think your patch looks fine. It certainly
BAW> meets my requirements, seems to work, and solves your
BAW> problem.
BAW> Unless I hear any objections, I'll go ahead and accept these
BAW> changes.
BG> Excellent! I'm really enjoying working with Mailman. Python
BG> is just so clean and easy to follow, it makes my life easy. :)
BG> Thanks for helping solve the (future) Debian users' problems.
No problem, thanks for the patch! Checking these in momentarily.
-Barry
participants (2)
-
barry@zope.com
-
Ben Gertzfield