]> git.ipfire.org Git - thirdparty/postfix.git/commitdiff
postfix-2.12-20140531
authorWietse Venema <wietse@porcupine.org>
Sat, 31 May 2014 05:00:00 +0000 (00:00 -0500)
committerViktor Dukhovni <postfix-users@dukhovni.org>
Sat, 31 May 2014 18:36:15 +0000 (14:36 -0400)
postfix/HISTORY
postfix/Makefile.in
postfix/conf/postmulti-script
postfix/makedefs
postfix/postfix-install
postfix/src/global/mail_version.h

index b06b38a50bd6c5148bb7b95a21fe8286f2969196..87eaa0ec507440365f3c2f519403b674efcc6ae5 100644 (file)
@@ -19859,3 +19859,19 @@ Apologies for any names omitted.
        automatically include files under the directory postfix-files.d.
        See INSTALL section "Building with Postfix shared libraries
        and database plugins".  File: dynamicmaps.c.
+
+20140530
+
+       Cleanup: add shlib_directory and plugin_directory to the
+       postmulti-script list of shared parameters. Viktor Dukhovni.
+       File: postmulti-script.
+
+       Cleanup: to avoid "postfix set-permission" errors, don't
+       create postfix-files entries for non-existent database
+       plugins. Problem reported by Viktor. File: Makefile.in.
+
+       Bugfix: we can't use "mv" to replace a symlink-to-directory.
+       Instead we now create all symlinks in place. Unfortunately
+       the "ln -n" option is not universally implemented, so we
+       remove the old symlink first.  Problem reported by Viktor.
+       File: postfix-install.
index 0e84d856875bf723d0646090fa9c12946a3388a5..9ff608a98f3871044821d3099375061f68d40677 100644 (file)
@@ -61,10 +61,19 @@ libexec/postfix-files: conf/postfix-files conf/makedefs.out Makefile
        elif [ "${PLUGIN_DIR}" = "no" -o "${PLUGIN_DIR}" = "" ]; then \
            sed -e '/^\$$plugin_directory/d' conf/postfix-files | $(EXPAND); \
        else \
-           $(EXPAND) conf/postfix-files; \
+           $(EXPAND) conf/postfix-files | awk -F: ' \
+               BEGIN { \
+                   count = split("'"$(DEFINED_MAP_TYPES)"'", names, " "); \
+                   for (n = 1; n <= count; n++) \
+                       have["$$plugin_directory/$(LIB_PREFIX)" names[n] \
+                           "$(LIB_SUFFIX)"] = 1; } \
+               /^[$$]plugin_directory.dynamicmaps/ { \
+                   print; next } \
+               /^[$$]plugin_directory.$(LIB_PREFIX)/ { \
+                   if (have[$$1]) print; next } \
+               { print } \
+           '; \
        fi) | case "$(MAKE_FIX)" in \
-       *cant-move-relative-symlink*) \
-           sed 's;:l:dynamic;:h:$plugin_directory/dynamic;';; \
         *) cat;; \
        esac > $@
 
index 417a8718ae0f634276c643c82f93b4f1333c8796..4d1a9feb4cf5d2106c10ab6e17c620ea85891a56 100644 (file)
@@ -156,6 +156,8 @@ create|import)
            manpage_directory
            sample_directory
            readme_directory
+           shlib_directory
+           plugin_directory
        "
 
        shift $#        # Needed on SunOS where bare "set --" is NOP!
index cd7bec92503b294ffbbe42a56887e45ed9b89ee9..c9b721945e8e728e1d828ddcc3ac3802f81e57e2 100644 (file)
@@ -534,7 +534,6 @@ ReliantUNIX-?.5.43) SYSTYPE=ReliantUnix543
                : ${CC=cc}
                CCARGS="$CCARGS"
                CCWARN='$(WARN)'
-               MAKE_FIX=cant-move-relative-symlink
                # Darwin > 1.3 uses awk and flat_namespace
                case $RELEASE in
                 1.[0-3]) AWK=gawk;;
index 416bd0aa6975bbdd09b7e4dd612e32b98e245c6e..a60cf2af4c0ae388d93d97d293eb461b157a63b3 100644 (file)
@@ -293,15 +293,12 @@ compare_or_symlink() {
     esac
     (test $link = "`myreadlink $2`" >/dev/null 2>&1 && echo Skipping $2...) || {
        echo Updating $2...
-       rm -f $tempdir/junk || exit 1
-       ln -s $link $tempdir/junk || exit 1
-       mv -f $tempdir/junk $2 || {
-           echo $0: Error: your mv command has trouble renaming symlinks. 1>&2
-           echo If you run Linux, upgrade to GNU fileutils-4.0 or better, 1>&2
-           echo or choose a tempdir that is in the same file system as $2. 1>&2
-           echo If you run FreeBSD, upgrade to version 5 or better. 1>&2
-           exit 1
-       }
+       # We create the symlink in place instead of using mv because:
+       # 1) some systems cannot move symlinks between file systems;
+       # 2) we cannot use mv to replace a symlink-to-directory;
+       # 3) "ln -n" is not in POSIX, therefore it's not portable.
+       # rm+ln is less atomic but this affects compatibility symlinks only.
+       rm -f $2 && ln -sf $link $2 || exit 1
     }
 }
 
@@ -707,9 +704,8 @@ do
            compare_or_replace $mode "$owner" "$group" lib/$file \
                    $SHLIB_DIRECTORY/$file || exit 1;;
        '$plugin_directory')
-           test ! -f plugins/$file ||
-               compare_or_replace $mode "$owner" "$group" plugins/$file \
-                   $PLUGIN_DIRECTORY/$file || exit 1;;
+           compare_or_replace $mode "$owner" "$group" plugins/$file \
+               $PLUGIN_DIRECTORY/$file || exit 1;;
        '$daemon_directory')
            compare_or_replace $mode "$owner" "$group" libexec/$file \
                $DAEMON_DIRECTORY/$file || exit 1;;
index cfdf8b794584167d3c684e883d73597052c5cb1b..ab7894a61cdd4aadde28972263ae204e1a730917 100644 (file)
@@ -20,7 +20,7 @@
   * Patches change both the patchlevel and the release date. Snapshots have no
   * patchlevel; they change the release date only.
   */
-#define MAIL_RELEASE_DATE      "20140530"
+#define MAIL_RELEASE_DATE      "20140531"
 #define MAIL_VERSION_NUMBER    "2.12"
 
 #ifdef SNAPSHOT