update: $(LIB_DIR)/$(LIB) $(HDRS)
-for i in $(HDRS); \
-diff -durN postfix-2.1.3.orig/src/global/Makefile.in postfix-2.1.3/src/global/Makefile.in
---- postfix-2.1.3.orig/src/global/Makefile.in 2004-06-22 15:38:56.931476412 +0200
-+++ postfix-2.1.3/src/global/Makefile.in 2004-06-22 15:39:56.167971280 +0200
-@@ -90,8 +90,11 @@
- LIB_DIR = ../../lib
- INC_DIR = ../../include
- MAKES =
-+LDAPSO = dict_ldap.so
-+MYSQLSO = dict_mysql.so
-+PGSQLSO = dict_pgsql.so
-
--.c.o:; $(CC) $(CFLAGS) -c $*.c
-+.c.o:; $(CC) -fPIC $(CFLAGS) -c $*.c
-
- all: $(LIB)
-
-@@ -101,14 +104,30 @@
- test: $(TESTPROG)
-
- $(LIB): $(OBJS)
-- $(AR) $(ARFL) $(LIB) $?
-- $(RANLIB) $(LIB)
-+ gcc -shared -Wl,-soname,libpostfix-global.so.1 -o $(LIB) $(OBJS)
-+
-+$(LDAPSO): dict_ldap.o $(LIB)
-+ gcc -shared -Wl,-soname,dict_ldap.so -o $@ $? -lldap -llber -L../../lib -lutil -L. -lglobal
-+
-+$(MYSQLSO): dict_mysql.o $(LIB)
-+ gcc -shared -Wl,-soname,dict_mysql.so -o $@ $? -lmysqlclient -L../../lib -lutil -L. -lglobal
-+
-+$(PGSQLSO): dict_pgsql.o $(LIB)
-+ gcc -shared -Wl,-soname,dict_pgsql.so -o $@ $? -lpq -L../../lib -lutil -L. -lglobal
-
- $(LIB_DIR)/$(LIB): $(LIB)
- cp $(LIB) $(LIB_DIR)
-- $(RANLIB) $(LIB_DIR)/$(LIB)
-
--update: $(LIB_DIR)/$(LIB) $(HDRS)
-+$(LIB_DIR)/$(LDAPSO): $(LDAPSO)
-+ cp $(LDAPSO) $(LIB_DIR)
-+
-+$(LIB_DIR)/$(MYSQLSO): $(MYSQLSO)
-+ cp $(MYSQLSO) $(LIB_DIR)
-+
-+$(LIB_DIR)/$(PGSQLSO): $(PGSQLSO)
-+ cp $(PGSQLSO) $(LIB_DIR)
-+
-+update: $(LIB_DIR)/$(LIB) $(LIB_DIR)/${LDAPSO} $(LIB_DIR)/${MYSQLSO} $(LIB_DIR)/${PGSQLSO} $(HDRS)
- -for i in $(HDRS); \
- do \
- cmp -s $$i $(INC_DIR)/$$i 2>/dev/null || cp $$i $(INC_DIR); \
-@@ -360,7 +379,7 @@
- lint $(DEFS) $(SRCS) $(LINTFIX)
-
- clean:
-- rm -f *.o $(LIB) *core $(TESTPROG) junk
-+ rm -f *.o $(LIB) $(LDAPSO) $(MYSQLSO) $(PGSQLSO) *core $(TESTPROG) junk
- rm -rf printfck
-
- tidy: clean
diff -durN postfix-2.1.3.orig/src/global/mail_conf.c postfix-2.1.3/src/global/mail_conf.c
--- postfix-2.1.3.orig/src/global/mail_conf.c 2004-04-10 16:52:51.000000000 +0200
+++ postfix-2.1.3/src/global/mail_conf.c 2004-06-22 15:39:24.247860093 +0200
+/*--*/
+
+#endif
-diff -dur postfix-2.1.3.orig/src/global/mail_dict.c postfix-2.1.3/src/global/mail_dict.c
---- postfix-2.1.3.orig/src/global/mail_dict.c 2004-01-04 19:53:27.000000000 +0100
-+++ postfix-2.1.3/src/global/mail_dict.c 2004-06-22 15:47:45.259202712 +0200
-@@ -45,15 +45,6 @@
-
- static DICT_OPEN_INFO dict_open_info[] = {
- DICT_TYPE_PROXY, dict_proxy_open,
--#ifdef HAS_LDAP
-- DICT_TYPE_LDAP, dict_ldap_open,
--#endif
--#ifdef HAS_MYSQL
-- DICT_TYPE_MYSQL, dict_mysql_open,
--#endif
--#ifdef HAS_PGSQL
-- DICT_TYPE_PGSQL, dict_pgsql_open,
--#endif
- 0,
- };
-
-
--- postfix-2.0.16.orig/conf/dynamicmaps.cf 1970-01-01 01:00:00.000000000 +0100
+++ postfix-2.0.16/conf/dynamicmaps.cf 2003-11-08 19:52:14.000000000 +0100
@@ -0,0 +1,9 @@
/* mail_params_init - configure built-in parameters */
void mail_params_init()
---- postfix-2.3.0/src/global/Makefile.in 2006-07-17 03:28:25.732653648 +0200
-+++ postfix-2.3.0/src/global/Makefile.in-new 2006-07-17 03:29:31.805609032 +0200
-@@ -32,7 +32,7 @@
- canon_addr.o cfg_parser.o cleanup_strerror.o cleanup_strflags.o \
- clnt_stream.o conv_time.o db_common.o debug_peer.o debug_process.o \
- defer.o deliver_completed.o deliver_flock.o deliver_pass.o \
-- deliver_request.o dict_ldap.o dict_mysql.o dict_pgsql.o \
-+ deliver_request.o \
- dict_proxy.o domain_list.o dot_lockfile.o dot_lockfile_as.o \
- dsb_scan.o dsn.o dsn_buf.o dsn_mask.o dsn_print.o dsn_util.o \
- ehlo_mask.o ext_prop.o file_id.o flush_clnt.o header_opts.o \
---- postfix-2.3.12/src/util/Makefile.in.orig 2007-07-31 01:18:35.000000000 +0200
-+++ postfix-2.3.12/src/util/Makefile.in 2007-08-26 17:34:55.300706718 +0200
-@@ -30,14 +30,14 @@
+diff -durN postfix-2.1.3.orig/src/util/sys_defs.h postfix-2.1.3/src/util/sys_defs.h
+--- postfix-2.1.3.orig/src/util/sys_defs.h 2004-06-22 15:38:57.190461088 +0200
++++ postfix-2.1.3/src/util/sys_defs.h 2004-06-22 15:39:24.255859620 +0200
+@@ -700,6 +700,7 @@
+ #define STATFS_IN_SYS_VFS_H
+ #define PREPEND_PLUS_TO_OPTSTRING
+ #define HAS_POSIX_REGEXP
++#define HAS_DLOPEN
+ #define NATIVE_SENDMAIL_PATH "/usr/sbin/sendmail"
+ #define NATIVE_MAILQ_PATH "/usr/bin/mailq"
+ #define NATIVE_NEWALIAS_PATH "/usr/bin/newaliases"
+@@ -754,6 +755,7 @@
+ #define STATFS_IN_SYS_VFS_H
+ #define PREPEND_PLUS_TO_OPTSTRING
+ #define HAS_POSIX_REGEXP
++#define HAS_DLOPEN
+ #define NATIVE_SENDMAIL_PATH "/usr/sbin/sendmail"
+ #define NATIVE_MAILQ_PATH "/usr/bin/mailq"
+ #define NATIVE_NEWALIAS_PATH "/usr/bin/newaliases"
+@@ -638,6 +640,7 @@
+ #define USE_STATFS
+ #define STATFS_IN_SYS_VFS_H
+ #define HAS_POSIX_REGEXP
++#define HAS_SHL_LOAD
+ #define NATIVE_SENDMAIL_PATH "/usr/sbin/sendmail"
+ #define NATIVE_MAILQ_PATH "/usr/bin/mailq"
+ #define NATIVE_NEWALIAS_PATH "/usr/bin/newaliases"
+@@ -673,6 +676,7 @@
+ #define USE_STATFS
+ #define STATFS_IN_SYS_VFS_H
+ #define HAS_POSIX_REGEXP
++#define HAS_SHL_LOAD
+ #define NATIVE_SENDMAIL_PATH "/usr/sbin/sendmail"
+ #define NATIVE_MAILQ_PATH "/usr/bin/mailq"
+ #define NATIVE_NEWALIAS_PATH "/usr/bin/newaliases"
+--- postfix-2.8.3/src/util/Makefile.in~ 2011-05-17 13:59:05.580000068 +0200
++++ postfix-2.8.3/src/util/Makefile.in 2011-05-17 14:10:13.870000068 +0200
+@@ -30,7 +30,7 @@
username.c valid_hostname.c vbuf.c vbuf_print.c vstream.c \
vstream_popen.c vstring.c vstring_vstream.c watchdog.c writable.c \
write_buf.c write_wait.c sane_basename.c format_tv.c allspace.c \
-- allascii.c load_file.c killme_after.c vstream_tweak.c upass_connect.c \
-+ allascii.c load_file.c killme_after.c vstream_tweak.c upass_connect.c load_lib.c \
- upass_listen.c upass_trigger.c
- OBJS = alldig.o allprint.o argv.o argv_split.o attr_clnt.o attr_print0.o \
- attr_print64.o attr_print_plain.o attr_scan0.o attr_scan64.o \
- attr_scan_plain.o auto_clnt.o base64_code.o basename.o binhash.o \
+- allascii.c load_file.c killme_after.c vstream_tweak.c \
++ allascii.c load_file.c killme_after.c vstream_tweak.c load_lib.c \
+ unix_pass_listen.c unix_pass_trigger.c edit_file.c inet_windowsize.c \
+ unix_pass_fd_fix.c dict_cache.c valid_utf_8.c dict_thash.c \
+ ip_match.c nbbio.c stream_pass_connect.c
+@@ -40,7 +40,7 @@
chroot_uid.o cidr_match.o clean_env.o close_on_exec.o concatenate.o \
ctable.o dict.o dict_alloc.o dict_cdb.o dict_cidr.o dict_db.o \
dict_dbm.o dict_debug.o dict_env.o dict_ht.o dict_ni.o dict_nis.o \
+ dict_nisplus.o dict_open.o dict_regexp.o dict_sdbm.o \
dict_static.o dict_tcp.o dict_unix.o dir_forest.o doze.o dummy_read.o \
dummy_write.o duplex_pipe.o environ.o events.o exec_command.o \
-@@ -62,7 +62,7 @@
+ fifo_listen.o fifo_trigger.o file_limit.o find_inet.o fsspace.o \
+@@ -65,7 +65,7 @@
username.o valid_hostname.o vbuf.o vbuf_print.o vstream.o \
vstream_popen.o vstring.o vstring_vstream.o watchdog.o writable.o \
write_buf.o write_wait.o sane_basename.o format_tv.o allspace.o \
-- allascii.o load_file.o killme_after.o vstream_tweak.o upass_connect.o \
-+ allascii.o load_file.o killme_after.o vstream_tweak.o upass_connect.o load_lib.o \
- upass_listen.o upass_trigger.o
- HDRS = argv.h attr.h attr_clnt.h auto_clnt.h base64_code.h binhash.h \
- chroot_uid.h cidr_match.h clean_env.h connect.h ctable.h dict.h \
-@@ -81,13 +81,14 @@
+- allascii.o load_file.o killme_after.o vstream_tweak.o \
++ allascii.o load_file.o killme_after.o vstream_tweak.o load_lib.o \
+ unix_pass_listen.o unix_pass_trigger.o edit_file.o inet_windowsize.o \
+ unix_pass_fd_fix.o dict_cache.o valid_utf_8.o dict_thash.o \
+ ip_match.o nbbio.o stream_pass_connect.o
+@@ -87,7 +87,7 @@
sigdelay.h sock_addr.h spawn_command.h split_at.h stat_as.h \
stringops.h sys_defs.h timed_connect.h timed_wait.h trigger.h \
username.h valid_hostname.h vbuf.h vbuf_print.h vstream.h vstring.h \
-- vstring_vstream.h watchdog.h format_tv.h load_file.h killme_after.h
-+ vstring_vstream.h watchdog.h format_tv.h load_file.h killme_after.h load_lib.h
+- vstring_vstream.h watchdog.h format_tv.h load_file.h killme_after.h \
++ vstring_vstream.h watchdog.h format_tv.h load_file.h killme_after.h load_lib.h \
+ edit_file.h dict_cache.h dict_thash.h \
+ ip_match.h nbbio.h
TESTSRC = fifo_open.c fifo_rdwr_bug.c fifo_rdonly_bug.c select_bug.c \
- stream_test.c dup2_pass_on_exec.c
- DEFS = -I. -D$(SYSTYPE)
+@@ -96,6 +96,7 @@
CFLAGS = $(DEBUG) $(OPT) $(DEFS)
FILES = Makefile $(SRCS) $(HDRS)
INCL =
LIB = libutil.a
TESTPROG= dict_open dup2_pass_on_exec events exec_command fifo_open \
fifo_rdonly_bug fifo_rdwr_bug fifo_trigger fsspace fullname \
-@@ -102,8 +103,9 @@
+@@ -111,8 +112,9 @@
LIB_DIR = ../../lib
INC_DIR = ../../include
+LIBS = $(LIB_DIR)/$(LIB) $(LIB_DIR)/$(PCRESO)
-.c.o:; $(CC) $(CFLAGS) -c $*.c
-+.c.o:; $(CC) -fPIC $(CFLAGS) -c $*.c
++.c.o:; $(CC) -fPIC $(CFLAGS) -c $*.c
all: $(LIB)
-@@ -114,15 +116,19 @@
+@@ -123,15 +125,19 @@
test: $(TESTPROG)
-for i in $(HDRS); \
do \
cmp -s $$i $(INC_DIR)/$$i 2>/dev/null || cp $$i $(INC_DIR); \
-@@ -144,7 +150,8 @@
- lint $(SRCS)
+@@ -153,7 +159,8 @@
+ lint $(DEFS) $(SRCS) $(LINTFIX)
clean:
- rm -f *.o $(LIB) *core $(TESTPROG) junk $(MAKES) *.tmp
rm -rf printfck
tidy: clean
-diff -durN postfix-2.1.3.orig/src/util/sys_defs.h postfix-2.1.3/src/util/sys_defs.h
---- postfix-2.1.3.orig/src/util/sys_defs.h 2004-06-22 15:38:57.190461088 +0200
-+++ postfix-2.1.3/src/util/sys_defs.h 2004-06-22 15:39:24.255859620 +0200
-@@ -700,6 +700,7 @@
- #define STATFS_IN_SYS_VFS_H
- #define PREPEND_PLUS_TO_OPTSTRING
- #define HAS_POSIX_REGEXP
-+#define HAS_DLOPEN
- #define NATIVE_SENDMAIL_PATH "/usr/sbin/sendmail"
- #define NATIVE_MAILQ_PATH "/usr/bin/mailq"
- #define NATIVE_NEWALIAS_PATH "/usr/bin/newaliases"
-@@ -754,6 +755,7 @@
- #define STATFS_IN_SYS_VFS_H
- #define PREPEND_PLUS_TO_OPTSTRING
- #define HAS_POSIX_REGEXP
-+#define HAS_DLOPEN
- #define NATIVE_SENDMAIL_PATH "/usr/sbin/sendmail"
- #define NATIVE_MAILQ_PATH "/usr/bin/mailq"
- #define NATIVE_NEWALIAS_PATH "/usr/bin/newaliases"
-@@ -638,6 +640,7 @@
- #define USE_STATFS
- #define STATFS_IN_SYS_VFS_H
- #define HAS_POSIX_REGEXP
-+#define HAS_SHL_LOAD
- #define NATIVE_SENDMAIL_PATH "/usr/sbin/sendmail"
- #define NATIVE_MAILQ_PATH "/usr/bin/mailq"
- #define NATIVE_NEWALIAS_PATH "/usr/bin/newaliases"
-@@ -673,6 +676,7 @@
- #define USE_STATFS
- #define STATFS_IN_SYS_VFS_H
- #define HAS_POSIX_REGEXP
-+#define HAS_SHL_LOAD
- #define NATIVE_SENDMAIL_PATH "/usr/sbin/sendmail"
- #define NATIVE_MAILQ_PATH "/usr/bin/mailq"
- #define NATIVE_NEWALIAS_PATH "/usr/bin/newaliases"
+--- postfix-2.8.3/src/global/mail_dict.c~ 2011-05-17 14:11:58.216666735 +0200
++++ postfix-2.8.3/src/global/mail_dict.c 2011-05-17 14:15:04.606666734 +0200
+@@ -46,18 +46,6 @@
+
+ static const DICT_OPEN_INFO dict_open_info[] = {
+ DICT_TYPE_PROXY, dict_proxy_open,
+-#ifdef HAS_LDAP
+- DICT_TYPE_LDAP, dict_ldap_open,
+-#endif
+-#ifdef HAS_MYSQL
+- DICT_TYPE_MYSQL, dict_mysql_open,
+-#endif
+-#ifdef HAS_PGSQL
+- DICT_TYPE_PGSQL, dict_pgsql_open,
+-#endif
+-#ifdef HAS_SQLITE
+- DICT_TYPE_SQLITE, dict_sqlite_open,
+-#endif
+ 0,
+ };
+
+--- postfix-2.8.3/src/global/Makefile.in~ 2011-05-17 14:11:58.243333401 +0200
++++ postfix-2.8.3/src/global/Makefile.in 2011-05-17 14:27:36.783333538 +0200
+@@ -35,7 +35,7 @@
+ canon_addr.o cfg_parser.o cleanup_strerror.o cleanup_strflags.o \
+ clnt_stream.o conv_time.o db_common.o debug_peer.o debug_process.o \
+ defer.o deliver_completed.o deliver_flock.o deliver_pass.o \
+- deliver_request.o dict_ldap.o dict_mysql.o dict_pgsql.o \
++ deliver_request.o \
+ dict_proxy.o dict_sqlite.o domain_list.o dot_lockfile.o dot_lockfile_as.o \
+ dsb_scan.o dsn.o dsn_buf.o dsn_mask.o dsn_print.o dsn_util.o \
+ ehlo_mask.o ext_prop.o file_id.o flush_clnt.o header_opts.o \
+@@ -106,8 +106,12 @@
+ LIB_DIR = ../../lib
+ INC_DIR = ../../include
+ MAKES =
++LDAPSO = dict_ldap.so
++MYSQLSO = dict_mysql.so
++PGSQLSO = dict_pgsql.so
++SQLITESO= dict_sqlite.so
+
+-.c.o:; $(CC) $(CFLAGS) -c $*.c
++.c.o:; $(CC) -fPIC $(CFLAGS) -c $*.c
+
+ all: $(LIB)
+
+@@ -119,14 +123,36 @@
+ test: $(TESTPROG)
+
+ $(LIB): $(OBJS)
+- $(AR) $(ARFL) $(LIB) $?
+- $(RANLIB) $(LIB)
++ gcc -shared -Wl,-soname,libpostfix-global.so.1 -o $(LIB) $(OBJS)
++
++$(LDAPSO): dict_ldap.o $(LIB)
++ gcc -shared -Wl,-soname,dict_ldap.so -o $@ $? -lldap -llber -L../../lib -lutil -L. -lglobal
++
++$(MYSQLSO): dict_mysql.o $(LIB)
++ gcc -shared -Wl,-soname,dict_mysql.so -o $@ $? -lmysqlclient -L../../lib -lutil -L. -lglobal
++
++$(PGSQLSO): dict_pgsql.o $(LIB)
++ gcc -shared -Wl,-soname,dict_pgsql.so -o $@ $? -lpq -L../../lib -lutil -L. -lglobal
++
++$(SQLITESO): dict_sqlite.o $(LIB)
++ gcc -shared -Wl,-soname,dict_sqlite.so -o $@ $? -lsqlite3 -L../../lib -lutil -L. -lglobal
+
+ $(LIB_DIR)/$(LIB): $(LIB)
+ cp $(LIB) $(LIB_DIR)
+- $(RANLIB) $(LIB_DIR)/$(LIB)
+
+-update: $(LIB_DIR)/$(LIB) $(HDRS)
++$(LIB_DIR)/$(LDAPSO): $(LDAPSO)
++ cp $(LDAPSO) $(LIB_DIR)
++
++$(LIB_DIR)/$(MYSQLSO): $(MYSQLSO)
++ cp $(MYSQLSO) $(LIB_DIR)
++
++$(LIB_DIR)/$(PGSQLSO): $(PGSQLSO)
++ cp $(PGSQLSO) $(LIB_DIR)
++
++$(LIB_DIR)/$(SQLITESO): $(SQLITESO)
++ cp $(SQLITESO) $(LIB_DIR)
++
++update: $(LIB_DIR)/$(LIB) $(LIB_DIR)/${LDAPSO} $(LIB_DIR)/${MYSQLSO} $(LIB_DIR)/${PGSQLSO} $(LIB_DIR)/${SQLITESO} $(HDRS)
+ -for i in $(HDRS); \
+ do \
+ cmp -s $$i $(INC_DIR)/$$i 2>/dev/null || cp $$i $(INC_DIR); \
+@@ -497,7 +523,7 @@
+ lint $(DEFS) $(SRCS) $(LINTFIX)
+
+ clean:
+- rm -f *.o $(LIB) *core $(TESTPROG) junk
++ rm -f *.o $(LIB) $(LDAPSO) $(MYSQLSO) $(PGSQLSO) $(SQLITESO) *core $(TESTPROG) junk
+ rm -rf printfck
+
+ tidy: clean