]> git.ipfire.org Git - thirdparty/postfix.git/commitdiff
postfix-2.12-20140524-nonprod 20140508-nonprod
authorWietse Venema <wietse@porcupine.org>
Sat, 24 May 2014 05:00:00 +0000 (00:00 -0500)
committerViktor Dukhovni <postfix-users@dukhovni.org>
Sun, 25 May 2014 02:34:42 +0000 (22:34 -0400)
38 files changed:
postfix/HISTORY
postfix/INSTALL
postfix/Makefile.in
postfix/README_FILES/CDB_README
postfix/README_FILES/INSTALL
postfix/README_FILES/LDAP_README
postfix/README_FILES/LMDB_README
postfix/README_FILES/MYSQL_README
postfix/README_FILES/PCRE_README
postfix/README_FILES/PGSQL_README
postfix/README_FILES/SQLITE_README
postfix/RELEASE_NOTES
postfix/conf/postfix-files
postfix/html/CDB_README.html
postfix/html/INSTALL.html
postfix/html/LDAP_README.html
postfix/html/LMDB_README.html
postfix/html/MYSQL_README.html
postfix/html/PCRE_README.html
postfix/html/PGSQL_README.html
postfix/html/SQLITE_README.html
postfix/html/postconf.5.html
postfix/makedefs
postfix/man/man5/postconf.5
postfix/mantools/postlink
postfix/postfix-install
postfix/proto/CDB_README.html
postfix/proto/INSTALL.html
postfix/proto/LDAP_README.html
postfix/proto/LMDB_README.html
postfix/proto/MYSQL_README.html
postfix/proto/PCRE_README.html
postfix/proto/PGSQL_README.html
postfix/proto/SQLITE_README.html
postfix/proto/postconf.proto
postfix/src/global/Makefile.in
postfix/src/global/mail_version.h
postfix/src/util/Makefile.in

index ac5d9fd54a358c97c26af069ae647ef1f20a1da6..3524b8d906351b6ac9b9b7cc0f47a3870d71a267 100644 (file)
@@ -19831,3 +19831,22 @@ Apologies for any names omitted.
 
        Cleanup: port for ancient Solaris9 revealed some non-portability.
        Files: master/Makefile.in, makedefs, sys_defs.h.
+
+20140524
+
+       Cleanup: specify database library dependencies with variables
+       named AUXLIBS_CDB, AUXLIBS_LDAP, etc. The global AUXLIBS
+       variable is still supported, but the new variables are
+       required when building dynamically-loadable building database
+       plugins.  Files: RELEASE_NOTES, INSTALL.html, CDB_README.html,
+       LDAP_README.html, LMDB_README.html, MYSQL_README.html,
+       PCRE_README.html, PGSQL_README.html, SQLITE_README.html,
+       makedefs, util/Makefile.in, global/Makefile.in.
+
+       Workaround: reportedly, MacOS can fail to move a symlink
+       with a relative target across file system boundaries, because
+       it examines the symlink with stat() instead of lstat().
+       Files: makedefs, Makefile.in.
+
+       Cleanup: use readlink to verify symlink target. File:
+       postfix-install.
index ea8d1dba87f08def0e08a1bfa6f320296d3a1874..715dddf8b928b4807bbe6e35d12f45f107e04d26 100644 (file)
@@ -201,6 +201,11 @@ where the type is a database type such as "ldap" or "lmdb", and where the
 version is the same as for Postfix shared libraries. The installed
 dynamicmaps.cf configuration file is given a suffix with the same version.
 
+NOTE: Postfix 2.12 expects that you specify database library dependencies with
+variables named AUXLIBS_CDB, AUXLIBS_LDAP, etc. The old AUXLIBS variable is
+still supported, but the new variables are required when building database
+plugins.
+
 To override the default location or shared-library version, specify, for
 example:
 
@@ -349,8 +354,13 @@ The following is an extensive list of names and values.
  _____________________________________________________________________________
 |Name/Value                   |Description                                   |
 |______________________________|______________________________________________|
-|AUXLIBS="object_library..."   |Specifies one or more non-default object      |
-|                             |libraries.                                    |
+|                             |Specifies one or more non-default object      |
+|                             |libraries. Postfix 2,12 and later specify some|
+|                             |of their database library dependencies with   |
+|AUXLIBS="object_library..."   |AUXLIBS_CDB, AUXLIBS_LDAP, AUXLIBS_LMDB,      |
+|                             |AUXLIBS_MYSQL, AUXLIBS_PCRE, AUXLIBS_PGSQL,   |
+|                             |AUXLIBS_SDBM, and AUXLIBS_SQLITE,             |
+|                             |respectively.                                 |
 |______________________________|______________________________________________|
 |CC=compiler_command          |Specifies a non-default compiler. On many     |
 |                             |systems, the default is gcc.                  |
index 281361019c52703e42efe09bdb23a47b836bd0d0..927a655ca435d35083c6e744dda7799efe7e535d 100644 (file)
@@ -55,14 +55,17 @@ libexec/post-install: conf/post-install
 
 libexec/postfix-files: conf/postfix-files conf/makedefs.out Makefile
        rm -f $@
-       if [ "${SHLIB_DIR}" = "no" -o "${SHLIB_DIR}" = "" ]; then \
+       (if [ "${SHLIB_DIR}" = "no" -o "${SHLIB_DIR}" = "" ]; then \
            sed -e '/^\$$shlib_directory/d' \
-               -e '/^\$$plugin_directory/d' conf/postfix-files >$@; \
+               -e '/^\$$plugin_directory/d' conf/postfix-files; \
        elif [ "${PLUGIN_DIR}" = "no" -o "${PLUGIN_DIR}" = "" ]; then \
-           sed -e '/^\$$plugin_directory/d' conf/postfix-files | $(EXPAND) >$@; \
+           sed -e '/^\$$plugin_directory/d' conf/postfix-files | $(EXPAND); \
        else \
-           $(EXPAND) conf/postfix-files >$@; \
-       fi
+           $(EXPAND) conf/postfix-files; \
+       fi) | case "$(MAKE_FIX)" in \
+       *cant-move-relative-symlink*) sed 's/:l:dynamic/:h:dynamic/';; \
+                                  *) cat;; \
+       esac > $@
 
 libexec/postfix-script: conf/postfix-script
        rm -f $@ && ln -f $? $@
@@ -127,6 +130,7 @@ tidy:       clean
        rm -f README_FILES/RELEASE_NOTES
        ln -s ../RELEASE_NOTES README_FILES
        rm -f bin/[!CRS]* lib/[!CRS]* include/[!CRS]* libexec/[!CRS]* plugins/[!CRS]* \
+           src/*/libpostfix-*.so.* src/*/libpostfix-*.dylib.* \
            src/*/postfix-*.so.* src/*/postfix-*.dylib.* \
            junk */junk */*/junk \
            *core */*core */*/*core \
index 502b7c4911cca2692232445f90b983b394cec01b..0b37e4cd426aab58942632acad23a6cf1078c901 100644 (file)
@@ -42,7 +42,7 @@ To build Postfix after you have installed tinycdb, use something like:
     % make tidy
     % CDB=../../../tinycdb-0.5
     % make -f Makefile.init makefiles "CCARGS=-DHAS_CDB -I$CDB" \
-        "AUXLIBS=$CDB/libcdb.a"
+        "AUXLIBS_CDB=$CDB/libcdb.a"
     % make
 
 Alternatively, for the D.J.B. version of CDB:
@@ -50,9 +50,14 @@ Alternatively, for the D.J.B. version of CDB:
     % make tidy
     % CDB=../../../cdb-0.75
     % make -f Makefile.init makefiles "CCARGS=-DHAS_CDB -I$CDB" \
-        "AUXLIBS=$CDB/cdb.a $CDB/alloc.a $CDB/buffer.a $CDB/unix.a $CDB/byte.a"
+        "AUXLIBS_CDB=$CDB/cdb.a $CDB/alloc.a $CDB/buffer.a $CDB/unix.a $CDB/
+    byte.a"
     % make
 
+Postfix versions before 2.12 should use AUXLIBS instead of AUXLIBS_CDB. Postfix
+2.12 and later still support the old global AUXLIBS variable, but AUXLIBS_CDB
+is required when building dynamically-loadable database plugins.
+
 After Postfix has been built with cdb support, you can use "cdb" tables
 wherever you can use read-only "hash", "btree" or "dbm" tables. However, the
 "p\bpo\bos\bst\btm\bma\bap\bp -\b-i\bi" (incremental record insertion) and "p\bpo\bos\bst\btm\bma\bap\bp -\b-d\bd" (incremental
index b058e42e5926ceec5d6ee84a6efe2995c63754e1..fab89619e79e3cbcf5c6fc22ec298de643ddb1c3 100644 (file)
@@ -201,6 +201,11 @@ where the type is a database type such as "ldap" or "lmdb", and where the
 version is the same as for Postfix shared libraries. The installed
 dynamicmaps.cf configuration file is given a suffix with the same version.
 
+NOTE: Postfix 2.12 expects that you specify database library dependencies with
+variables named AUXLIBS_CDB, AUXLIBS_LDAP, etc. The old AUXLIBS variable is
+still supported, but the new variables are required when building database
+plugins.
+
 To override the default location or shared-library version, specify, for
 example:
 
@@ -349,8 +354,13 @@ The following is an extensive list of names and values.
  _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b 
 |N\bNa\bam\bme\be/\b/V\bVa\bal\blu\bue\be                    |D\bDe\bes\bsc\bcr\bri\bip\bpt\bti\bio\bon\bn                                   |
 |_\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b|_\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b |
-|AUXLIBS="object_library..."   |Specifies one or more non-default object      |
-|                              |libraries.                                    |
+|                              |Specifies one or more non-default object      |
+|                              |libraries. Postfix 2,12 and later specify some|
+|                              |of their database library dependencies with   |
+|AUXLIBS="object_library..."   |AUXLIBS_CDB, AUXLIBS_LDAP, AUXLIBS_LMDB,      |
+|                              |AUXLIBS_MYSQL, AUXLIBS_PCRE, AUXLIBS_PGSQL,   |
+|                              |AUXLIBS_SDBM, and AUXLIBS_SQLITE,             |
+|                              |respectively.                                 |
 |_\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b|_\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b _\b |
 |CC=compiler_command           |Specifies a non-default compiler. On many     |
 |                              |systems, the default is gcc.                  |
index 4079dd47c3bc6f1dd02d25ea910078c06972dcbb..b99506aaf47775cc01a154612af5f7e444e94c5a 100644 (file)
@@ -26,9 +26,6 @@ Topics covered in this document:
 
 B\bBu\bui\bil\bld\bdi\bin\bng\bg P\bPo\bos\bst\btf\bfi\bix\bx w\bwi\bit\bth\bh L\bLD\bDA\bAP\bP s\bsu\bup\bpp\bpo\bor\brt\bt
 
-[Note: instructions to build as a dynamicmaps.cf-style plugin will be added
-later.]
-
 These instructions assume that you build Postfix from source code as described
 in the INSTALL document. Some modification may be required if you build Postfix
 from a vendor-specific source package.
@@ -55,14 +52,18 @@ this in the top level of your Postfix source tree should work:
 
     % make tidy
     % make makefiles CCARGS="-I/usr/local/include -DHAS_LDAP" \
-        AUXLIBS="-L/usr/local/lib -lldap -L/usr/local/lib -llber"
+        AUXLIBS_LDAP="-L/usr/local/lib -lldap -L/usr/local/lib -llber"
+
+Postfix versions before 2.12 should use AUXLIBS instead of AUXLIBS_LDAP.
+Postfix 2.12 and later still support the old global AUXLIBS variable, but
+AUXLIBS_LDAP is required when building dynamically-loadable database plugins.
 
 On Solaris 2.x you may have to specify run-time link information, otherwise
 ld.so will not find some of the shared libraries:
 
     % make tidy
     % make makefiles CCARGS="-I/usr/local/include -DHAS_LDAP" \
-        AUXLIBS="-L/usr/local/lib -R/usr/local/lib -lldap \
+        AUXLIBS_LDAP="-L/usr/local/lib -R/usr/local/lib -lldap \
                 -L/usr/local/lib -R/usr/local/lib -llber"
 
 The 'make tidy' command is needed only if you have previously built Postfix
index 214a8c20af6b32e7d2325f06d9a18eba039f8c33..fc8917f760b04bfee470ecd252da6508ae7b3195 100644 (file)
@@ -24,20 +24,21 @@ This document describes:
 
 B\bBu\bui\bil\bld\bdi\bin\bng\bg P\bPo\bos\bst\btf\bfi\bix\bx w\bwi\bit\bth\bh L\bLM\bMD\bDB\bB s\bsu\bup\bpp\bpo\bor\brt\bt
 
-[Note: instructions to build as a dynamicmaps.cf-style plugin will be added
-later.]
-
 Postfix normally does not enable LMDB support. To build Postfix with LMDB
 support, use something like:
 
     % make makefiles CCARGS="-DHAS_LMDB -I/usr/local/include" \
-        AUXLIBS="-L/usr/local/lib -llmdb"
+        AUXLIBS_LMDB="-L/usr/local/lib -llmdb"
     % make
 
+Postfix versions before 2.12 should use AUXLIBS instead of AUXLIBS_LMDB.
+Postfix 2.12 and later still support the old global AUXLIBS variable, but
+AUXLIBS_LMDB is required when building dynamically-loadable database plugins.
+
 Solaris may need this:
 
     % make makefiles CCARGS="-DHAS_LMDB -I/usr/local/include" \
-        AUXLIBS="-R/usr/local/lib -L/usr/local/lib -llmdb"
+        AUXLIBS_LMDB="-R/usr/local/lib -L/usr/local/lib -llmdb"
     % make
 
 The exact pathnames depend on how LMDB was installed.
@@ -50,7 +51,7 @@ When building Postfix fails with:
 
 Add the "-lpthread" library to the "make makefiles" command.
 
-    % make makefiles .... AUXLIBS="... -lpthread"
+    % make makefiles .... AUXLIBS_LMDB="... -lpthread"
 
 C\bCo\bon\bnf\bfi\big\bgu\bur\bri\bin\bng\bg L\bLM\bMD\bDB\bB s\bse\bet\btt\bti\bin\bng\bgs\bs
 
index 796dce5e11e4bf828b99bdfb527a65f46b45e91f..41cf47df98e486e3ea64a9d5ed8e232fb1ed8b9b 100644 (file)
@@ -17,9 +17,6 @@ service.
 
 B\bBu\bui\bil\bld\bdi\bin\bng\bg P\bPo\bos\bst\btf\bfi\bix\bx w\bwi\bit\bth\bh M\bMy\byS\bSQ\bQL\bL s\bsu\bup\bpp\bpo\bor\brt\bt
 
-[Note: instructions to build as a dynamicmaps.cf-style plugin will be added
-later.]
-
 These instructions assume that you build Postfix from source code as described
 in the INSTALL document. Some modification may be required if you build Postfix
 from a vendor-specific source package.
@@ -36,17 +33,21 @@ obtained from:
 
 In order to build Postfix with mysql map support, you will need to add -
 DHAS_MYSQL and -I for the directory containing the mysql headers, and the
-mysqlclient library (and libm) to AUXLIBS, for example:
+mysqlclient library (and libm) to AUXLIBS_MYSQL, for example:
 
     make -f Makefile.init makefiles \
         'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include' \
-        'AUXLIBS=-L/usr/local/mysql/lib -lmysqlclient -lz -lm'
+        'AUXLIBS_MYSQL=-L/usr/local/mysql/lib -lmysqlclient -lz -lm'
+
+Postfix versions before 2.12 should use AUXLIBS instead of AUXLIBS_MYSQL.
+Postfix 2.12 and later still support the old global AUXLIBS variable, but
+AUXLIBS_MYSQL is required when building dynamically-loadable database plugins.
 
 On Solaris, use this instead:
 
     make -f Makefile.init makefiles \
         'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include' \
-        'AUXLIBS=-L/usr/local/mysql/lib -R/usr/local/mysql/lib \
+        'AUXLIBS_MYSQL=-L/usr/local/mysql/lib -R/usr/local/mysql/lib \
             -lmysqlclient -lz -lm'
 
 Then, just run 'make'. This requires libz, the compression library. Older mysql
index f11476225bf5dacb366fdb788db5bdfa4ace5866..051efaa810ee557420370f4ed783f99209b29ce7 100644 (file)
@@ -16,9 +16,6 @@ pcre_table(5) manual page. Information about PCRE itself can be found at http:/
 
 B\bBu\bui\bil\bld\bdi\bin\bng\bg P\bPo\bos\bst\btf\bfi\bix\bx w\bwi\bit\bth\bh P\bPC\bCR\bRE\bE s\bsu\bup\bpp\bpo\bor\brt\bt
 
-[Note: instructions to build as a dynamicmaps.cf-style plugin will be added
-later.]
-
 These instructions assume that you build Postfix from source code as described
 in the INSTALL document. Some modification may be required if you build Postfix
 from a vendor-specific source package.
@@ -39,17 +36,21 @@ NOTE: pcre versions prior to 2.06 cannot be used.
 
 In order to build Postfix with PCRE support you need to add -DHAS_PCRE and a -
 I for the PCRE include file to CCARGS, and add the path to the PCRE library to
-AUXLIBS, for example:
+AUXLIBS_PCRE, for example:
 
     make -f Makefile.init makefiles \
         "CCARGS=-DHAS_PCRE -I/usr/local/include" \
-        "AUXLIBS=-L/usr/local/lib -lpcre"
+        "AUXLIBS_PCRE=-L/usr/local/lib -lpcre"
+
+Postfix versions before 2.12 should use AUXLIBS instead of AUXLIBS_PCRE.
+Postfix 2.12 and later still support the old global AUXLIBS variable, but
+AUXLIBS_PCRE is required when building dynamically-loadable database plugins.
 
 Solaris needs run-time path information too:
 
     make -f Makefile.init makefiles \
         "CCARGS=-DHAS_PCRE -I/usr/local/include" \
-        "AUXLIBS=-L/usr/local/lib -R/usr/local/lib -lpcre"
+        "AUXLIBS_PCRE=-L/usr/local/lib -R/usr/local/lib -lpcre"
 
 T\bTh\bhi\bin\bng\bgs\bs t\bto\bo k\bkn\bno\bow\bw
 
index 604e6a4b24e70d5bf3f0e70f4119057448ab1082..b05bb2546909124cb48d637e102ea7a32c0d6d29 100644 (file)
@@ -17,9 +17,6 @@ service.
 
 B\bBu\bui\bil\bld\bdi\bin\bng\bg P\bPo\bos\bst\btf\bfi\bix\bx w\bwi\bit\bth\bh P\bPo\bos\bst\btg\bgr\bre\beS\bSQ\bQL\bL s\bsu\bup\bpp\bpo\bor\brt\bt
 
-[Note: instructions to build as a dynamicmaps.cf-style plugin will be added
-later.]
-
 These instructions assume that you build Postfix from source code as described
 in the INSTALL document. Some modification may be required if you build Postfix
 from a vendor-specific source package.
@@ -37,7 +34,11 @@ For example:
     % make tidy
     % make -f Makefile.init makefiles \
             'CCARGS=-DHAS_PGSQL -I/usr/local/include/pgsql' \
-            'AUXLIBS=-L/usr/local/lib -lpq'
+            'AUXLIBS_PGSQL=-L/usr/local/lib -lpq'
+
+Postfix versions before 2.12 should use AUXLIBS instead of AUXLIBS_PGSQL.
+Postfix 2.12 and later still support the old global AUXLIBS variable, but
+AUXLIBS_PGSQL is required when building dynamically-loadable database plugins.
 
 Then just run 'make'.
 
index 97f6bbe88b82fdb7abf36724f20ad9fb911f35e8..0d1c475c0b9ad067796e775bf5039d0f0f07b3a0 100644 (file)
@@ -11,9 +11,6 @@ if you want.
 
 B\bBu\bui\bil\bld\bdi\bin\bng\bg P\bPo\bos\bst\btf\bfi\bix\bx w\bwi\bit\bth\bh S\bSQ\bQL\bLi\bit\bte\be s\bsu\bup\bpp\bpo\bor\brt\bt
 
-[Note: instructions to build as a dynamicmaps.cf-style plugin will be added
-later.]
-
 The Postfix SQLite client utilizes the sqlite3 library, which can be obtained
 from:
 
@@ -27,7 +24,11 @@ For example:
 
     make -f Makefile.init makefiles \
          'CCARGS=-DHAS_SQLITE -I/usr/local/include' \
-         'AUXLIBS=-L/usr/local/lib -lsqlite3 -lpthread'
+         'AUXLIBS_SQLITE=-L/usr/local/lib -lsqlite3 -lpthread'
+
+Postfix versions before 2.12 should use AUXLIBS instead of AUXLIBS_SQLITE.
+Postfix 2.12 and later still support the old global AUXLIBS variable, but
+AUXLIBS_SQLITE is required when building dynamically-loadable database plugins.
 
 Then, just run 'make'.
 
index 01fe66826f29c929953760cb98d94f4995bb5549..65fd80e7587362a8a088710e8d7ca10f6b204092 100644 (file)
@@ -16,29 +16,64 @@ specifies the release date of a stable release or snapshot release.
 If you upgrade from Postfix 2.10 or earlier, read RELEASE_NOTES-2.11
 before proceeding.
 
-Major changes with snapshot 20140522
+Incompatible changes with snapshot 20140524
+===========================================
+
+Postfix 2.12 expects that you specify database library dependencies
+with variables named AUXLIBS_CDB, AUXLIBS_LDAP, etc.  The old AUXLIBS
+variable is still supported, but the new variables are required
+when building dynamically-loadable database plugins. See CDB_README,
+LDAP_README, etc. for details.
+
+Major changes with snapshot 20140524
 ====================================
 
 Support to build Postfix with Postfix shared libraries, and with
-support for database plugins. Postfix shared libraries introduce
-minor runtime overhead and result in smaller Postfix executable
-files. Postfix database plugins are useful primarily for people
-who distribute pre-compiled packages.
+dynamically-loadable database plugins. Postfix shared libraries
+introduce minor runtime overhead and result in smaller Postfix
+executable files. Dynamically-loadable database plugins are useful
+primarily for people who install pre-compiled packages.
 
 This is based on Debian code by LaMont Jones, and based on a port
 by Viktor Dukhovni. Currently, support exists for recent versions
-of Linux, FreeBSD and MacOS X.
+of Linux, FreeBSD and MacOS X, as well as ancient Solaris 9.
 
-Postfix shared libraries and database plugins require changes in
-the Postix build procedure (specifically, the makedefs and Makefile.in
-files). These changes are introduced early in the annual Postfix
+Postfix shared libraries and dynamically-loadable database plugins
+require changes in the Postfix build procedure (specifically, the
+makedefs and Makefile.in files, and scripts that install or update
+Postfix).  These changes are introduced early in the annual Postfix
 development cycle to give down-stream maintainers sufficient time
 to prepare their build systems for the next stable Postfix release.
 
+Building with Postfix shared libraries and database plugins
+-----------------------------------------------------------
+
+Please see the INSTALL section "Building with Postfix shared libraries
+and database plugins" for fine-tuning details. 
+
+To build with Postfix shared libraries (libpostfix-*.so.*), use:
+
+% make makefiles shared=yes ...other arguments...
+
+To build with dynamicmaps.cf support and dynamically-loadable
+database plugins (postfix-*.so.*), use:
+
+% make makefiles dynamicmaps=yes ...other arguments...
+
+This implicitly enables support for libpostfix-*.so.* shared
+libraries. Database plugin support is available for CDB, LDAP, LMDB,
+MySQL, PCRE, PGSQL, SDBM, and SQLITE.
+
+NOTE: Postfix 2.12 expects that you specify database library
+dependencies with variables named AUXLIBS_CDB, AUXLIBS_LDAP, etc.
+The old AUXLIBS variable is still supported, but the new variables
+are required when building dynamically-loadable database plugins.
+See CDB_README, LDAP_README, etc. for details.
+
 Differences with Debian
 -----------------------
 
-Besides changes to the Postfix "build" system as described below,
+Besides changes to the Postfix "build" system as described above,
 the user-visible changes with respect to Debian are:
 
 - The new shlib_directory parameter specifies the location of the
@@ -55,13 +90,7 @@ the user-visible changes with respect to Debian are:
   among all Postfix instances just like postfix-files and other
   files. Files in /etc are meant to be instance-specific.
 
-Building with Postfix shared libraries and database plugins
------------------------------------------------------------
-
-Please see the INSTALL section "Building with Postfix shared libraries
-and database plugins". 
-
-Fuurther information
+Further information
 --------------------
 
 Maintainers may also benefit from the makedefs documentation
index 7fc51c016b2488a515b9eb0256f15760a19948a5..16b70d0184d005ab32b01e56aa61665f0e8f5e3a 100644 (file)
@@ -43,6 +43,8 @@
 # it is a good idea to "u" all the files that have special ownership or
 # permissions, so that running "make install" fixes any glitches.
 #
+# Note: order matters. Update shared libraries and database plugins
+# before daemon/command-line programs.
 $config_directory:d:root:-:755:u
 $data_directory:d:$mail_owner:-:700:uc
 $daemon_directory:d:root:-:755:u
@@ -64,11 +66,13 @@ $queue_directory/public:d:$mail_owner:$setgid_group:710:uc
 $queue_directory/pid:d:root:-:755:uc
 $queue_directory/saved:d:$mail_owner:-:700:ucr
 $queue_directory/trace:d:$mail_owner:-:700:ucr
+# Update shared libraries before daemon or command-line programs.
 $shlib_directory/lib${LIB_PREFIX}util${LIB_SUFFIX}:f:root:-:755
 $shlib_directory/lib${LIB_PREFIX}global${LIB_SUFFIX}:f:root:-:755
 $shlib_directory/lib${LIB_PREFIX}dns${LIB_SUFFIX}:f:root:-:755
 $shlib_directory/lib${LIB_PREFIX}tls${LIB_SUFFIX}:f:root:-:755
 $shlib_directory/lib${LIB_PREFIX}master${LIB_SUFFIX}:f:root:-:755
+# Update database plugins before daemon or command-line programs.
 $plugin_directory/${LIB_PREFIX}cdb${LIB_SUFFIX}:f:root:-:755
 $plugin_directory/${LIB_PREFIX}ldap${LIB_SUFFIX}:f:root:-:755
 $plugin_directory/${LIB_PREFIX}lmdb${LIB_SUFFIX}:f:root:-:755
index b0a56242a4f05aeb3dc2baf379f51137c48bdf2c..cfde3b64fee1177ddd90a8a80ad430809a024f83 100644 (file)
@@ -67,7 +67,7 @@ like: </p>
 % make tidy
 % CDB=../../../tinycdb-0.5
 % make -f Makefile.init makefiles "CCARGS=-DHAS_CDB -I$CDB" \
-    "AUXLIBS=$CDB/libcdb.a"
+    "<a href="CDB_README.html">AUXLIBS_CDB</a>=$CDB/libcdb.a"
 % make
 </pre>
 </blockquote>
@@ -79,11 +79,16 @@ like: </p>
 % make tidy
 % CDB=../../../cdb-0.75
 % make -f Makefile.init makefiles "CCARGS=-DHAS_CDB -I$CDB" \
-    "AUXLIBS=$CDB/cdb.a $CDB/alloc.a $CDB/buffer.a $CDB/unix.a $CDB/byte.a"
+    "<a href="CDB_README.html">AUXLIBS_CDB</a>=$CDB/cdb.a $CDB/alloc.a $CDB/buffer.a $CDB/unix.a $CDB/byte.a"
 % make
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+<a href="CDB_README.html">AUXLIBS_CDB</a>. Postfix 2.12 and later still support the old global
+AUXLIBS variable, but <a href="CDB_README.html">AUXLIBS_CDB</a> is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> After Postfix has been built with cdb support, you can use
 "cdb" tables wherever you can use read-only "hash", "btree" or
 "dbm" tables. However, the "<b>postmap -i</b>" (incremental record
index 7098dd9e66e4b98fb2d92b7ad59e984c1fcce780..4f865c4a1c27ba9603e20cc09c71d5b2c0067dd3 100644 (file)
@@ -302,6 +302,11 @@ is the same as for Postfix shared libraries. The installed
 dynamicmaps.cf configuration file is given a suffix with the same
 version. </p>
 
+<p> NOTE: Postfix 2.12 expects that you specify database library
+dependencies with variables named <a href="CDB_README.html">AUXLIBS_CDB</a>, <a href="LDAP_README.html">AUXLIBS_LDAP</a>, etc.
+The old AUXLIBS variable is still supported, but the new variables
+are required when building database plugins. </p>
+
 <p> To override the default location or shared-library version,
 specify, for example: </p>
 
@@ -513,7 +518,10 @@ $ make
 <tr> <th colspan="2"> Name/Value </th> <th> Description </th> </tr>
 
 <tr> <td colspan="2"> AUXLIBS="object_library..."</td> <td> Specifies
-one or more non-default object libraries. </td> </tr>
+one or more non-default object libraries. Postfix 2,12 and later
+specify some of their database library dependencies with <a href="CDB_README.html">AUXLIBS_CDB</a>,
+<a href="LDAP_README.html">AUXLIBS_LDAP</a>, <a href="LMDB_README.html">AUXLIBS_LMDB</a>, <a href="MYSQL_README.html">AUXLIBS_MYSQL</a>, <a href="PCRE_README.html">AUXLIBS_PCRE</a>, <a href="PGSQL_README.html">AUXLIBS_PGSQL</a>,
+<a href="SDBM_README.html">AUXLIBS_SDBM</a>, and <a href="SQLITE_README.html">AUXLIBS_SQLITE</a>, respectively. </td> </tr>
 
 <tr> <td colspan="2"> CC=compiler_command</td> <td> Specifies a
 non-default compiler. On many systems, the default is <tt>gcc</tt>.
index 820d4bd5ed1bf23a245164d873c3f04942cc76e7..20f55cd22f11297407f29d49ccc50873288c48e0 100644 (file)
@@ -55,9 +55,6 @@ it to each. </p>
 
 <h2><a name="build">Building Postfix with LDAP support</a></h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> These instructions assume that you build Postfix from source
 code as described in the <a href="INSTALL.html">INSTALL</a> document. Some modification may   
 be required if you build Postfix from a vendor-specific source
@@ -95,10 +92,15 @@ your Postfix source tree should work: </p>
 <pre>
 % make tidy
 % make makefiles CCARGS="-I/usr/local/include -DHAS_LDAP" \
-    AUXLIBS="-L/usr/local/lib -lldap -L/usr/local/lib -llber"
+    <a href="LDAP_README.html">AUXLIBS_LDAP</a>="-L/usr/local/lib -lldap -L/usr/local/lib -llber"
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+<a href="LDAP_README.html">AUXLIBS_LDAP</a>. Postfix 2.12 and later still support the old global 
+AUXLIBS variable, but <a href="LDAP_README.html">AUXLIBS_LDAP</a> is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> On Solaris 2.x you may have to specify run-time link information,
 otherwise ld.so will not find some of the shared libraries: </p>
 
@@ -106,7 +108,7 @@ otherwise ld.so will not find some of the shared libraries: </p>
 <pre>
 % make tidy
 % make makefiles CCARGS="-I/usr/local/include -DHAS_LDAP" \
-    AUXLIBS="-L/usr/local/lib -R/usr/local/lib -lldap \
+    <a href="LDAP_README.html">AUXLIBS_LDAP</a>="-L/usr/local/lib -R/usr/local/lib -lldap \
             -L/usr/local/lib -R/usr/local/lib -llber"
 </pre>
 </blockquote>
index d80007f560bb83a4761c2ce4b07925e2adfea3f8..ed8f1eea1138b760e56046be3e61c5b804d76c87 100644 (file)
@@ -44,26 +44,28 @@ the database file without the ".lmdb" suffix. </p>
 
 <h2><a name="with_lmdb">Building Postfix with LMDB support</a></h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> Postfix normally does not enable LMDB support.  To
 build Postfix with LMDB support, use something like: </p>
 
 <blockquote>
 <pre>
 % make makefiles CCARGS="-DHAS_LMDB -I/usr/local/include" \
-    AUXLIBS="-L/usr/local/lib -llmdb"
+    <a href="LMDB_README.html">AUXLIBS_LMDB</a>="-L/usr/local/lib -llmdb"
 % make
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+<a href="LMDB_README.html">AUXLIBS_LMDB</a>. Postfix 2.12 and later still support the old global
+AUXLIBS variable, but <a href="LMDB_README.html">AUXLIBS_LMDB</a> is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> Solaris may need this: </p>
 
 <blockquote>
 <pre>
 % make makefiles CCARGS="-DHAS_LMDB -I/usr/local/include" \
-    AUXLIBS="-R/usr/local/lib -L/usr/local/lib -llmdb"
+    <a href="LMDB_README.html">AUXLIBS_LMDB</a>="-R/usr/local/lib -L/usr/local/lib -llmdb"
 % make
 </pre>
 </blockquote>
@@ -84,7 +86,7 @@ undefined reference to `pthread_mutex_lock'
 
 <blockquote>
 <pre>
-% make makefiles .... AUXLIBS="... -lpthread"
+% make makefiles .... <a href="LMDB_README.html">AUXLIBS_LMDB</a>="... -lpthread"
 </pre>
 </blockquote>
 
index d85e6ba04bbc9384a1e580f853d8f241de843ac2..e2e7df0906b2a1c7b1369d87d35f9ebe807d5a2f 100644 (file)
@@ -33,9 +33,6 @@ clients by using the Postfix <a href="proxymap.8.html">proxymap(8)</a> service.
 
 <h2>Building Postfix with MySQL support</h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> These instructions assume that you build Postfix from source
 code as described in the <a href="INSTALL.html">INSTALL</a> document. Some modification may
 be required if you build Postfix from a vendor-specific source
@@ -55,23 +52,28 @@ which can be obtained from: </p>
 
 <p> In order to build Postfix with mysql map support, you will need to add
 -DHAS_MYSQL and -I for the directory containing the mysql headers, and
-the mysqlclient library (and libm) to AUXLIBS, for example: </p>
+the mysqlclient library (and libm) to <a href="MYSQL_README.html">AUXLIBS_MYSQL</a>, for example: </p>
 
 <blockquote>
 <pre>
 make -f Makefile.init makefiles \
     'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include' \
-    'AUXLIBS=-L/usr/local/mysql/lib -lmysqlclient -lz -lm'
+    '<a href="MYSQL_README.html">AUXLIBS_MYSQL</a>=-L/usr/local/mysql/lib -lmysqlclient -lz -lm'
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+<a href="MYSQL_README.html">AUXLIBS_MYSQL</a>. Postfix 2.12 and later still support the old global
+AUXLIBS variable, but <a href="MYSQL_README.html">AUXLIBS_MYSQL</a> is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> On Solaris, use this instead: </p>
 
 <blockquote>
 <pre>
 make -f Makefile.init makefiles \
     'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include' \
-    'AUXLIBS=-L/usr/local/mysql/lib -R/usr/local/mysql/lib \
+    '<a href="MYSQL_README.html">AUXLIBS_MYSQL</a>=-L/usr/local/mysql/lib -R/usr/local/mysql/lib \
         -lmysqlclient -lz -lm'
 </pre>
 </blockquote>
index 7385d6f54aed1ad48b26a6464ca744c61c2ff14b..2dadc2580e9169ecd45fef4ae18eaceede4d384b 100644 (file)
@@ -32,9 +32,6 @@ itself can be found at <a href="http://www.pcre.org/">http://www.pcre.org/</a>.
 
 <h2>Building Postfix with PCRE support</h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> These instructions assume that you build Postfix from source
 code as described in the <a href="INSTALL.html">INSTALL</a> document. Some modification may
 be required if you build Postfix from a vendor-specific source
@@ -59,23 +56,28 @@ Expressions), which can be obtained from: </p>
 
 <p> In order to build Postfix with PCRE support you need to add
 -DHAS_PCRE and a -I for the PCRE include file to CCARGS, and add
-the path to the PCRE library to AUXLIBS, for example: </p>
+the path to the PCRE library to <a href="PCRE_README.html">AUXLIBS_PCRE</a>, for example: </p>
 
 <blockquote>
 <pre>
 make -f Makefile.init makefiles \
     "CCARGS=-DHAS_PCRE -I/usr/local/include" \
-    "AUXLIBS=-L/usr/local/lib -lpcre"
+    "<a href="PCRE_README.html">AUXLIBS_PCRE</a>=-L/usr/local/lib -lpcre"
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+<a href="PCRE_README.html">AUXLIBS_PCRE</a>. Postfix 2.12 and later still support the old global
+AUXLIBS variable, but <a href="PCRE_README.html">AUXLIBS_PCRE</a> is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> Solaris needs run-time path information too: </p>
 
 <blockquote>
 <pre>
 make -f Makefile.init makefiles \
     "CCARGS=-DHAS_PCRE -I/usr/local/include" \
-    "AUXLIBS=-L/usr/local/lib -R/usr/local/lib -lpcre"
+    "<a href="PCRE_README.html">AUXLIBS_PCRE</a>=-L/usr/local/lib -R/usr/local/lib -lpcre"
 </pre>
 </blockquote>
 
index f7c643d4fe6cc020327d324a18452a7c69bb38df..601b1259bd9b431079c581ca25527d2dc9ab7779 100644 (file)
@@ -33,9 +33,6 @@ clients by using the Postfix <a href="proxymap.8.html">proxymap(8)</a> service.
 
 <h2>Building Postfix with PostgreSQL support</h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> These instructions assume that you build Postfix from source
 code as described in the <a href="INSTALL.html">INSTALL</a> document. Some modification may
 be required if you build Postfix from a vendor-specific source
@@ -56,10 +53,15 @@ the location of the libpq library file. </p>
 % make tidy
 % make -f Makefile.init makefiles \
         'CCARGS=-DHAS_PGSQL -I/usr/local/include/pgsql' \
-        'AUXLIBS=-L/usr/local/lib -lpq'
+        '<a href="PGSQL_README.html">AUXLIBS_PGSQL</a>=-L/usr/local/lib -lpq'
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+<a href="PGSQL_README.html">AUXLIBS_PGSQL</a>. Postfix 2.12 and later still support the old global
+AUXLIBS variable, but <a href="PGSQL_README.html">AUXLIBS_PGSQL</a> is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> Then just run 'make'.  </p>
 
 <h2>Configuring PostgreSQL lookup tables</h2>
index e1987243c7c3aa84c94251df37a5d869c6b44fae..53866c3a6f454bbc4046d578331afa6ceac49d28 100644 (file)
@@ -26,9 +26,6 @@ databases: you can use one for a <a href="virtual.5.html">virtual(5)</a> table,
 
 <h2>Building Postfix with SQLite support</h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> The Postfix SQLite client utilizes the sqlite3 library,
 which can be obtained from: </p>
 
@@ -47,10 +44,15 @@ name of the standard POSIX thread library (pthread).  For example:
 <pre>
 make -f Makefile.init makefiles \
      'CCARGS=-DHAS_SQLITE -I/usr/local/include' \
-     'AUXLIBS=-L/usr/local/lib -lsqlite3 -lpthread'
+     '<a href="SQLITE_README.html">AUXLIBS_SQLITE</a>=-L/usr/local/lib -lsqlite3 -lpthread'
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+<a href="SQLITE_README.html">AUXLIBS_SQLITE</a>. Postfix 2.12 and later still support the old global 
+AUXLIBS variable, but <a href="SQLITE_README.html">AUXLIBS_SQLITE</a> is required when building 
+dynamically-loadable database plugins.  </p>
+
 <p> Then, just run 'make'.</p>
 
 <h2>Using SQLite tables</h2>
index 61c316fed5f1d3a5b2bc2bd90d4618085df7e0ff..9ebfa0ffa1eaf2f30340fdaf21094b77c1f284e3 100644 (file)
@@ -9557,6 +9557,12 @@ earlier: "<b>/etc/postfix/post-install set-permissions</b>".
 This parameter defaults to "no" when Postfix shared libraries are
 disabled at compile time. </p>
 
+<p> NOTE: You can change the location of these files after Postfix
+is built. However, you may have to run ldconfig if you move the
+libpostfix-*.so.* files to a non-system directory.  No ldconfig is
+needed if you keep the libpostfix-*.so.* files in the compiled-in
+default $<a href="postconf.5.html#shlib_directory">shlib_directory</a> location. </p>
+
 <p> This feature is available in Postfix 2.12 and later. </p>
 
 
index 6ca70bb818371e8996b7b0dabd56a198a5509282..fdaced829bbc47d3816fce632cb7860087c2bf47 100644 (file)
 #      environment variables. Use quotes if variables contain
 #      whitespace or shell meta characters.
 # .IP \fBAUXLIBS=\fIobject_library...\fR
-#      Specifies one or more non-default object libraries.
+#      Specifies one or more non-default object libraries. Postfix
+#      2,12 and later specify some of their database library
+#      dependencies with AUXLIBS_CDB, AUXLIBS_LDAP, AUXLIBS_LMDB,
+#      AUXLIBS_MYSQL, AUXLIBS_PCRE, AUXLIBS_PGSQL, AUXLIBS_SDBM,
+#      and AUXLIBS_SQLITE, respectively.
 # .IP \fBCC=\fIcompiler_command\fR
 #      Specifies a non-default compiler. On many systems, the default
 #      is \fBgcc\fR.
@@ -76,9 +80,9 @@
 # .IP \fBdynamicmaps=yes\fR
 # .IP \fBdynamicmaps=no\fR
 #      Enable (disable) Postfix builds with the configuration file
-#      $plugin_directory/dynamicmaps.cf for database plugins
-#      typically named postfix-*.so.*.  The setting "dynamicmaps=yes"
-#      implicitly enables Postfix shared libraries.
+#      $plugin_directory/dynamicmaps.cf for dynamically-loadable
+#      database plugins typically named postfix-*.so.*.  The setting
+#      "dynamicmaps=yes" implicitly enables Postfix shared libraries.
 # .IP \fIinstallation_parameter\fB=\fIvalue\fR...
 #      Override the compiled-in default value of the specified
 #      installation parameter(s). The following parameters are
@@ -530,6 +534,7 @@ 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;;
@@ -664,7 +669,7 @@ case "$CCARGS" in
           *)   pcre_cflags=`(pcre-config --cflags) 2>/dev/null` &&
                    pcre_libs=`(pcre-config --libs) 2>/dev/null` && {
                        CCARGS="$CCARGS -DHAS_PCRE $pcre_cflags"
-                       AUXLIBS="$AUXLIBS $pcre_libs"
+                       AUXLIBS_PCRE="$pcre_libs"
                }
                ;;
 esac
@@ -707,7 +712,8 @@ sendmail_path_macro=DEF_SENDMAIL_PATH
 shlib_directory_macro=DEF_SHLIB_DIR
 
 # shlib_directory and plugin_directory are checked here because "no"
-# is not a good answer.  Instead, build with "shared=no".
+# is not a good answer.  Instead, build with "dynamicmaps=no" or
+# "shared=no" as appropriate.
 
 for parm_name in command_directory config_directory daemon_directory \
        data_directory mailq_path newaliases_path plugin_directory \
@@ -866,7 +872,7 @@ no|"")
     PLUGIN_LD=
     ;;
 
-*)  error "Specify \"shared=yes\" or \"shared=no\"" 1>&2
+*)  error "Specify \"shared=yes\" or \"shared=no\""
     ;;
 esac
 
@@ -896,21 +902,39 @@ DEFINED_MAP_TYPES=`
        END { print names }
 '`
 
-sed 's/  / /g' <<EOF
+# Propagate AUXLIBS_FOO or merge them into global AUXLIBS (i.e. SYSLIBS).
+
+PLUGGABLE_MAPS="CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE"
+
+case "$plugin_directory" in
+/*) for name in $PLUGGABLE_MAPS
+    do
+       eval test -n "\"\$AUXLIBS_$name\"" && 
+           eval PLUGIN_AUXLIBS="\"\$PLUGIN_AUXLIBS
+AUXLIBS_$name = \$AUXLIBS_$name\""
+    done;;
+ *) for name in $PLUGGABLE_MAPS
+    do
+       eval AUXLIBS="\"\$AUXLIBS \$AUXLIBS_$name\""
+    done;;
+esac
+
+sed 's/   */ /g' <<EOF
 # System-dependent settings and compiler/linker overrides.
 SYSTYPE        = $SYSTYPE
 _AR    = $_AR
 ARFL   = $ARFL
 _RANLIB        = $_RANLIB
-SYSLIBS        = $AUXLIBS $SYSLIBS
+SYSLIBS        = $AUXLIBS $SYSLIBS $PLUGIN_AUXLIBS
 CC     = $CC $CCARGS $CCWARN
 OPT    = $OPT
 DEBUG  = $DEBUG
 AWK    = $AWK
 STRCASE = $STRCASE
-EXPORT = AUXLIBS='$AUXLIBS' CCARGS='$CCARGS' OPT='$OPT' DEBUG='$DEBUG'
+EXPORT = CCARGS='$CCARGS' OPT='$OPT' DEBUG='$DEBUG'
 WARN   = $WARN
 DEFINED_MAP_TYPES = $DEFINED_MAP_TYPES
+MAKE_FIX = $MAKE_FIX
 # Switch between Postfix static and shared libraries.
 AR     = $AR
 RANLIB = $RANLIB
index 6a0efd347621926743545372cea71dc17412f3eb..7e0ae6db5491c90342375d53c48df7e48443b92b 100644 (file)
@@ -5849,6 +5849,12 @@ The location of Postfix shared libraries (libpostfix-*.so.*).
 This parameter defaults to "no" when Postfix shared libraries are
 disabled at compile time.
 .PP
+NOTE: You can change the location of these files after Postfix
+is built. However, you may have to run ldconfig if you move the
+libpostfix-*.so.* files to a non-system directory.  No ldconfig is
+needed if you keep the libpostfix-*.so.* files in the compiled-in
+default $shlib_directory location.
+.PP
 This feature is available in Postfix 2.12 and later.
 .SH show_user_unknown_table_name (default: yes)
 Display the name of the recipient table in the "User unknown"
index d04fb54c694e0dfa95f98552208b406c2d27c760..72181e65d45b2a34a07fa8b1691ec6811b0fff44 100755 (executable)
@@ -1131,6 +1131,10 @@ while (<>) {
     s/\b(lmtp):/<a href="lmtp.8.html">$1<\/a>:/g;
     s/\b(local):/<a href="local.8.html">$1<\/a>:/g;
     s/([^\/])\b(virtual):/$1<a href="virtual.8.html">$2<\/a>:/g;
+
+    # Database library dependencies.
+
+    s/\b(AUXLIBS_)([A-Z]+)\b/<a href="$2_README.html">$1$2<\/a>/g;
 }
 continue {
     if ($printit)
index a935476f9994c6c6e66326709324d74235b85923..123afc756a4c24b21516fa7b2649d563a84011fc 100644 (file)
@@ -263,30 +263,37 @@ compare_or_replace() {
     }
 }
 
+myreadlink() {
+    ls -l -- "$@" | awk '
+        /->/ { print $NF; next } 
+        { exit(1) }  
+    '
+}
+
 compare_or_symlink() {
-    (cmp $1 $2 >/dev/null 2>&1 && echo Skipping $2...) || {
+    case $1 in
+    /*) dest=`echo $1 | sed '
+           s;^'$install_root';;
+           s;/\./;/;g
+           s;//*;/;g
+           s;^/;;
+       '`
+       link=`echo $2 | sed '
+           s;^'$install_root';;
+           s;/\./;/;g
+           s;//*;/;g
+           s;^/;;
+           s;/[^/]*$;/;
+           s;[^/]*/;../;g
+           s;$;'$dest';
+       '`
+       ;;
+     *) link=$1
+       ;;
+    esac
+    (test $link = "`myreadlink $2`" >/dev/null 2>&1 && echo Skipping $2...) || {
        echo Updating $2...
        rm -f $tempdir/junk || exit 1
-       case $1 in
-       /*) dest=`echo $1 | sed '
-               s;^'$install_root';;
-               s;/\./;/;g
-               s;//*;/;g
-               s;^/;;
-           '`
-           link=`echo $2 | sed '
-               s;^'$install_root';;
-               s;/\./;/;g
-               s;//*;/;g
-               s;^/;;
-               s;/[^/]*$;/;
-               s;[^/]*/;../;g
-               s;$;'$dest';
-           '`
-           ;;
-        *) link=$1
-           ;;
-       esac
        ln -s $link $tempdir/junk || exit 1
        mv -f $tempdir/junk $2 || {
            echo $0: Error: your mv command has trouble renaming symlinks. 1>&2
index afe8a82eeea7135e800bcefdadc90a0e97f0101f..24f709da83c26ae206ce4af386bba0e1fa851119 100644 (file)
@@ -67,7 +67,7 @@ like: </p>
 % make tidy
 % CDB=../../../tinycdb-0.5
 % make -f Makefile.init makefiles "CCARGS=-DHAS_CDB -I$CDB" \
-    "AUXLIBS=$CDB/libcdb.a"
+    "AUXLIBS_CDB=$CDB/libcdb.a"
 % make
 </pre>
 </blockquote>
@@ -79,11 +79,16 @@ like: </p>
 % make tidy
 % CDB=../../../cdb-0.75
 % make -f Makefile.init makefiles "CCARGS=-DHAS_CDB -I$CDB" \
-    "AUXLIBS=$CDB/cdb.a $CDB/alloc.a $CDB/buffer.a $CDB/unix.a $CDB/byte.a"
+    "AUXLIBS_CDB=$CDB/cdb.a $CDB/alloc.a $CDB/buffer.a $CDB/unix.a $CDB/byte.a"
 % make
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+AUXLIBS_CDB. Postfix 2.12 and later still support the old global
+AUXLIBS variable, but AUXLIBS_CDB is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> After Postfix has been built with cdb support, you can use
 "cdb" tables wherever you can use read-only "hash", "btree" or
 "dbm" tables. However, the "<b>postmap -i</b>" (incremental record
index d0824c1c66ba01584ec42a536e45bc957c2d13ba..6f09e9fdc0bd18acc6b572c52520af9f284988d5 100644 (file)
@@ -302,6 +302,12 @@ is the same as for Postfix shared libraries. The installed
 dynamicmaps.cf configuration file is given a suffix with the same
 version. </p>
 
+<p> NOTE: Postfix 2.12 expects that you specify database library
+dependencies with variables named AUXLIBS_CDB, AUXLIBS_LDAP, etc.
+The old AUXLIBS variable is still supported, but the new variables
+are required when building database plugins. See CDB_README,
+LDAP_README, etc. for details. </p>
+
 <p> To override the default location or shared-library version,
 specify, for example: </p>
 
@@ -513,7 +519,10 @@ $ make
 <tr> <th colspan="2"> Name/Value </th> <th> Description </th> </tr>
 
 <tr> <td colspan="2"> AUXLIBS="object_library..."</td> <td> Specifies
-one or more non-default object libraries. </td> </tr>
+one or more non-default object libraries. Postfix 2,12 and later
+specify some of their database library dependencies with AUXLIBS_CDB,
+AUXLIBS_LDAP, AUXLIBS_LMDB, AUXLIBS_MYSQL, AUXLIBS_PCRE, AUXLIBS_PGSQL,
+AUXLIBS_SDBM, and AUXLIBS_SQLITE, respectively. </td> </tr>
 
 <tr> <td colspan="2"> CC=compiler_command</td> <td> Specifies a
 non-default compiler. On many systems, the default is <tt>gcc</tt>.
index af16bc55e5e02363575a00a838c3a36b5ad32ea7..bf4ea3736ed526417fd121bd0ad353834e115992 100644 (file)
@@ -55,9 +55,6 @@ it to each. </p>
 
 <h2><a name="build">Building Postfix with LDAP support</a></h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> These instructions assume that you build Postfix from source
 code as described in the INSTALL document. Some modification may   
 be required if you build Postfix from a vendor-specific source
@@ -95,10 +92,15 @@ your Postfix source tree should work: </p>
 <pre>
 % make tidy
 % make makefiles CCARGS="-I/usr/local/include -DHAS_LDAP" \
-    AUXLIBS="-L/usr/local/lib -lldap -L/usr/local/lib -llber"
+    AUXLIBS_LDAP="-L/usr/local/lib -lldap -L/usr/local/lib -llber"
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+AUXLIBS_LDAP. Postfix 2.12 and later still support the old global 
+AUXLIBS variable, but AUXLIBS_LDAP is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> On Solaris 2.x you may have to specify run-time link information,
 otherwise ld.so will not find some of the shared libraries: </p>
 
@@ -106,7 +108,7 @@ otherwise ld.so will not find some of the shared libraries: </p>
 <pre>
 % make tidy
 % make makefiles CCARGS="-I/usr/local/include -DHAS_LDAP" \
-    AUXLIBS="-L/usr/local/lib -R/usr/local/lib -lldap \
+    AUXLIBS_LDAP="-L/usr/local/lib -R/usr/local/lib -lldap \
             -L/usr/local/lib -R/usr/local/lib -llber"
 </pre>
 </blockquote>
index e7bcdcba835f0f5613763dc223924369ddd1f08b..16e68a793a76468601659d5947089c363405ed2c 100644 (file)
@@ -44,26 +44,28 @@ the database file without the ".lmdb" suffix. </p>
 
 <h2><a name="with_lmdb">Building Postfix with LMDB support</a></h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> Postfix normally does not enable LMDB support.  To
 build Postfix with LMDB support, use something like: </p>
 
 <blockquote>
 <pre>
 % make makefiles CCARGS="-DHAS_LMDB -I/usr/local/include" \
-    AUXLIBS="-L/usr/local/lib -llmdb"
+    AUXLIBS_LMDB="-L/usr/local/lib -llmdb"
 % make
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+AUXLIBS_LMDB. Postfix 2.12 and later still support the old global
+AUXLIBS variable, but AUXLIBS_LMDB is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> Solaris may need this: </p>
 
 <blockquote>
 <pre>
 % make makefiles CCARGS="-DHAS_LMDB -I/usr/local/include" \
-    AUXLIBS="-R/usr/local/lib -L/usr/local/lib -llmdb"
+    AUXLIBS_LMDB="-R/usr/local/lib -L/usr/local/lib -llmdb"
 % make
 </pre>
 </blockquote>
@@ -84,7 +86,7 @@ undefined reference to `pthread_mutex_lock'
 
 <blockquote>
 <pre>
-% make makefiles .... AUXLIBS="... -lpthread"
+% make makefiles .... AUXLIBS_LMDB="... -lpthread"
 </pre>
 </blockquote>
 
index 5d99c5de9e633cb283ebf5e48704bba822690f68..efa67d245ca0042817d09babe0ec73808d9ef512 100644 (file)
@@ -33,9 +33,6 @@ clients by using the Postfix proxymap(8) service. </p>
 
 <h2>Building Postfix with MySQL support</h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> These instructions assume that you build Postfix from source
 code as described in the INSTALL document. Some modification may
 be required if you build Postfix from a vendor-specific source
@@ -55,23 +52,28 @@ which can be obtained from: </p>
 
 <p> In order to build Postfix with mysql map support, you will need to add
 -DHAS_MYSQL and -I for the directory containing the mysql headers, and
-the mysqlclient library (and libm) to AUXLIBS, for example: </p>
+the mysqlclient library (and libm) to AUXLIBS_MYSQL, for example: </p>
 
 <blockquote>
 <pre>
 make -f Makefile.init makefiles \
     'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include' \
-    'AUXLIBS=-L/usr/local/mysql/lib -lmysqlclient -lz -lm'
+    'AUXLIBS_MYSQL=-L/usr/local/mysql/lib -lmysqlclient -lz -lm'
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+AUXLIBS_MYSQL. Postfix 2.12 and later still support the old global
+AUXLIBS variable, but AUXLIBS_MYSQL is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> On Solaris, use this instead: </p>
 
 <blockquote>
 <pre>
 make -f Makefile.init makefiles \
     'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include' \
-    'AUXLIBS=-L/usr/local/mysql/lib -R/usr/local/mysql/lib \
+    'AUXLIBS_MYSQL=-L/usr/local/mysql/lib -R/usr/local/mysql/lib \
         -lmysqlclient -lz -lm'
 </pre>
 </blockquote>
index c25b9aedca0003d44997aaf030fbf1853e290867..480aebdcf82d16e8a14481d614323cad6a45d66b 100644 (file)
@@ -32,9 +32,6 @@ itself can be found at http://www.pcre.org/. </p>
 
 <h2>Building Postfix with PCRE support</h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> These instructions assume that you build Postfix from source
 code as described in the INSTALL document. Some modification may
 be required if you build Postfix from a vendor-specific source
@@ -59,23 +56,28 @@ ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/.
 
 <p> In order to build Postfix with PCRE support you need to add
 -DHAS_PCRE and a -I for the PCRE include file to CCARGS, and add
-the path to the PCRE library to AUXLIBS, for example: </p>
+the path to the PCRE library to AUXLIBS_PCRE, for example: </p>
 
 <blockquote>
 <pre>
 make -f Makefile.init makefiles \
     "CCARGS=-DHAS_PCRE -I/usr/local/include" \
-    "AUXLIBS=-L/usr/local/lib -lpcre"
+    "AUXLIBS_PCRE=-L/usr/local/lib -lpcre"
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+AUXLIBS_PCRE. Postfix 2.12 and later still support the old global
+AUXLIBS variable, but AUXLIBS_PCRE is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> Solaris needs run-time path information too: </p>
 
 <blockquote>
 <pre>
 make -f Makefile.init makefiles \
     "CCARGS=-DHAS_PCRE -I/usr/local/include" \
-    "AUXLIBS=-L/usr/local/lib -R/usr/local/lib -lpcre"
+    "AUXLIBS_PCRE=-L/usr/local/lib -R/usr/local/lib -lpcre"
 </pre>
 </blockquote>
 
index 907c694298d9a76f892dacf3ed65a4e23b4fe16e..92e3af1ffad6042956d5b87faad9a29bb8273298 100644 (file)
@@ -33,9 +33,6 @@ clients by using the Postfix proxymap(8) service. </p>
 
 <h2>Building Postfix with PostgreSQL support</h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> These instructions assume that you build Postfix from source
 code as described in the INSTALL document. Some modification may
 be required if you build Postfix from a vendor-specific source
@@ -56,10 +53,15 @@ the location of the libpq library file. </p>
 % make tidy
 % make -f Makefile.init makefiles \
         'CCARGS=-DHAS_PGSQL -I/usr/local/include/pgsql' \
-        'AUXLIBS=-L/usr/local/lib -lpq'
+        'AUXLIBS_PGSQL=-L/usr/local/lib -lpq'
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+AUXLIBS_PGSQL. Postfix 2.12 and later still support the old global
+AUXLIBS variable, but AUXLIBS_PGSQL is required when building
+dynamically-loadable database plugins.  </p>
+
 <p> Then just run 'make'.  </p>
 
 <h2>Configuring PostgreSQL lookup tables</h2>
index 2894aa1c5babf19d977cb6c6c73e8ea42012a732..2d03bf70e548923db24bf05d0b76ae1cc14c9c71 100644 (file)
@@ -26,9 +26,6 @@ access(5) table, and one for an aliases(5) table if you want.  </p>
 
 <h2>Building Postfix with SQLite support</h2>
 
-<p> [Note: instructions to build as a dynamicmaps.cf-style plugin 
-will be added later.] </p>
-
 <p> The Postfix SQLite client utilizes the sqlite3 library,
 which can be obtained from: </p>
 
@@ -47,10 +44,15 @@ name of the standard POSIX thread library (pthread).  For example:
 <pre>
 make -f Makefile.init makefiles \
      'CCARGS=-DHAS_SQLITE -I/usr/local/include' \
-     'AUXLIBS=-L/usr/local/lib -lsqlite3 -lpthread'
+     'AUXLIBS_SQLITE=-L/usr/local/lib -lsqlite3 -lpthread'
 </pre>
 </blockquote>
 
+<p> Postfix versions before 2.12 should use AUXLIBS instead of
+AUXLIBS_SQLITE. Postfix 2.12 and later still support the old global 
+AUXLIBS variable, but AUXLIBS_SQLITE is required when building 
+dynamically-loadable database plugins.  </p>
+
 <p> Then, just run 'make'.</p>
 
 <h2>Using SQLite tables</h2>
index e7553f837480b72ff3e61627c5fc8f7653c2d69d..79e9581f079afb924fd99891581db11a1be26a9a 100644 (file)
@@ -15904,6 +15904,12 @@ deliveries.  See default_delivery_status_filter for details.  </p>
 This parameter defaults to "no" when Postfix shared libraries are
 disabled at compile time. </p>
 
+<p> NOTE: You can change the location of these files after Postfix
+is built. However, you may have to run ldconfig if you move the
+libpostfix-*.so.* files to a non-system directory.  No ldconfig is
+needed if you keep the libpostfix-*.so.* files in the compiled-in
+default $shlib_directory location. </p>
+
 <p> This feature is available in Postfix 2.12 and later. </p>
 
 %PARAM plugin_directory see 'postconf -d' output
index 4b513142b995a55c1ef5c530ad0ba078e72bab17..2cde9463daffcec5808151a0a841893dad90941f 100644 (file)
@@ -127,7 +127,7 @@ MAKES       =
 
 .c.o:; $(CC) $(SHLIB_CFLAGS) $(CFLAGS) -c $*.c
 
-all: $(LIB) $(PLUGIN_MAP_SO) $(PLUGIN_MAP_OBJ)
+all: $(LIB) $(PLUGIN_MAP_SO_MAKE) $(PLUGIN_MAP_OBJ)
 
 $(OBJS) $(PLUGIN_MAP_OBJ): ../../conf/makedefs.out
 
@@ -145,30 +145,32 @@ $(LIB_DIR)/$(LIB): $(LIB)
        cp $(LIB) $(LIB_DIR)
        $(RANLIB) $(LIB_DIR)/$(LIB)
 
-plugin_map_so: $(PLUGIN_MAP_SO)
+plugin_map_so_make: $(PLUGIN_MAP_SO)
 
 $(LIB_PREFIX)ldap$(LIB_SUFFIX): dict_ldap.o
-       $(PLUGIN_LD) -o $@ dict_ldap.o
+       $(PLUGIN_LD) -o $@ dict_ldap.o $(AUXLIBS_LDAP) $(SYSLIBS)
 
 $(LIB_PREFIX)mysql$(LIB_SUFFIX): dict_mysql.o
-       $(PLUGIN_LD) -o $@ dict_mysql.o
+       $(PLUGIN_LD) -o $@ dict_mysql.o $(AUXLIBS_MYSQL) $(SYSLIBS)
 
 $(LIB_PREFIX)pgsql$(LIB_SUFFIX): dict_pgsql.o
-       $(PLUGIN_LD) -o $@ dict_pgsql.o
+       $(PLUGIN_LD) -o $@ dict_pgsql.o $(AUXLIBS_PGSQL) $(SYSLIBS)
 
 $(LIB_PREFIX)sqlite$(LIB_SUFFIX): dict_sqlite.o
-       $(PLUGIN_LD) -o $@ dict_sqlite.o
+       $(PLUGIN_LD) -o $@ dict_sqlite.o $(AUXLIBS_SQLITE) $(SYSLIBS)
+
+$(LIB_PREFIX)cdb$(LIB_SUFFIX): mkmap_cdb.o $(LIB_DIR)/dict_cdb.o
+       $(PLUGIN_LD) -o $@ mkmap_cdb.o $(LIB_DIR)/dict_cdb.o \
+           $(AUXLIBS_CDB) $(SYSLIBS)
 
 $(LIB_PREFIX)lmdb$(LIB_SUFFIX): mkmap_lmdb.o $(LIB_DIR)/dict_lmdb.o \
-       $(LIB_DIR)/slmdb.o
+           $(LIB_DIR)/slmdb.o
        $(PLUGIN_LD) -o $@ mkmap_lmdb.o $(LIB_DIR)/dict_lmdb.o \
-       $(LIB_DIR)/slmdb.o
-
-$(LIB_PREFIX)cdb$(LIB_SUFFIX): mkmap_cdb.o $(LIB_DIR)/dict_cdb.o
-       $(PLUGIN_LD) -o $@ mkmap_cdb.o $(LIB_DIR)/dict_cdb.o
+           $(LIB_DIR)/slmdb.o $(AUXLIBS_LMDB) $(SYSLIBS)
 
 $(LIB_PREFIX)sdbm$(LIB_SUFFIX): mkmap_sdbm.o $(LIB_DIR)/dict_sdbm.o
-       $(PLUGIN_LD) -o $@ mkmap_sdbm.o $(LIB_DIR)/dict_sdbm.o
+       $(PLUGIN_LD) -o $@ mkmap_sdbm.o $(LIB_DIR)/dict_sdbm.o \
+           $(AUXLIBS_SDBM) $(SYSLIBS)
 
 update: $(LIB_DIR)/$(LIB) $(HDRS) $(PLUGIN_MAP_SO_UPDATE)
        -for i in $(HDRS); \
index 6272c6c3135baefd545bf1568f58fa6bd7ffeea8..ab05f85471c5c0af1ede8ae50e3d5c9c2d3739ba 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      "20140523"
+#define MAIL_RELEASE_DATE      "20140524"
 #define MAIL_VERSION_NUMBER    "2.12"
 
 #ifdef SNAPSHOT
index 60e9e97bd06976ae135f7f0d3578ed1b57ade1f4..56a1ccadf5fdad4707d568c065d0159347487690 100644 (file)
@@ -153,7 +153,7 @@ $(LIB_DIR)/$(LIB): $(LIB)
 plugin_map_so_make: $(PLUGIN_MAP_SO)
 
 $(LIB_PREFIX)pcre$(LIB_SUFFIX): dict_pcre.o
-       $(PLUGIN_LD) -o $@ dict_pcre.o
+       $(PLUGIN_LD) -o $@ dict_pcre.o $(AUXLIBS_PCRE) $(SYSLIBS)
 
 update: $(LIB_DIR)/$(LIB) $(HDRS) $(PLUGIN_MAP_SO_UPDATE) \
        $(PLUGIN_MAP_OBJ_UPDATE)