Danny Sauer wrote:
I always use mysql_config to get the correct includes and whatnot for mysql. Well, if you let "always" mean "most of the time"... :)
Anyway, you can do this: make -f Makefile.init makefiles \ "CCARGS=-DHAS_MYSQL `mysql_config --cflags`" \ "AUXLIBS=`mysql_config --libs`" and possibly have stuff work a bit better. It may not fix your problem, but it does make things a bit easier.
BTW, I'm not real big on moving headers around to locations other than where the pakages put them, because then I have to remember what I did. If I leave stuff alone, then other packages assumptions are generally gonna work. I like things to work. :)
--Danny
"CCARGS=-DHAS_MYSQL `mysql_config --cflags`" \ "AUXLIBS=`mysql_config --libs`" make -f Makefile.in MAKELEVEL= Makefiles set -e; for i in src/util src/global src/dns src/master src/postfix src/smtpstone src/sendmail src/error src/pickup src/cleanup src/smtpd src/local src/lmtp src/trivial-rewrite src/qmgr src/oqmgr src/smtp src/bounce src/pipe src/showq src/postalias src/postcat src/postconf src/postdrop src/postkick src/postlock src/postlog src/postmap src/postqueue src/postsuper src/qmqpd src/spawn src/flush src/verify src/virtual src/proxymap; do \ (set -e; echo "[$i]"; cd $i; rm -f Makefile; \ make -f Makefile.in Makefile MAKELEVEL=) || exit 1; \ done; [src/util] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/global] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/dns] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/master] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postfix] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/smtpstone] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/sendmail] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/error] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/pickup] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/cleanup] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/smtpd] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/local] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/lmtp] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/trivial-rewrite] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/qmgr] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/oqmgr] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/smtp] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/bounce] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/pipe] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/showq] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postalias] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postcat] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postconf] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postdrop] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postkick] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postlock] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postlog] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postmap] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postqueue] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/postsuper] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/qmqpd] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/spawn] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/flush] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/verify] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile [src/virtual] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs; cat Makefile.in) Makefile [src/proxymap] (set -e; echo "# DO NOT EDIT"; /bin/sh ../../makedefs && cat Makefile.in) Makefile rm -f Makefile; (set -e; /bin/sh makedefs && cat Makefile.in) >Makefile (echo "# Do not edit -- this file documents how Postfix was built for your machine."; /bin/sh makedefs) >makedefs.tmp set +e; if cmp makedefs.tmp conf/makedefs.out; then rm makedefs.tmp; \ else mv makedefs.tmp conf/makedefs.out; fi >/dev/null 2>/dev/null
I tried your suggestion, and now get a different error. Here's the log: ------------ linux:~/install_files/postfix-2.1.5 # make -f Makefile.init makefiles \ linux:~/install_files/postfix-2.1.5 # make install set -e; for i in src/util src/global src/dns src/master src/postfix src/smtpstone src/sendmail src/error src/pickup src/cleanup src/smtpd src/local src/lmtp src/trivial-rewrite src/qmgr src/oqmgr src/smtp src/bounce src/pipe src/showq src/postalias src/postcat src/postconf src/postdrop src/postkick src/postlock src/postlog src/postmap src/postqueue src/postsuper src/qmqpd src/spawn src/flush src/verify src/virtual src/proxymap; do \ (set -e; echo "[$i]"; cd $i; make 'CC=gcc -Wmissing-prototypes -Wformat -DHAS_MYSQL -I/usr/include/mysql -mcpu =i486 -fno-strength-reduce -DHAS_PCRE ' update MAKELEVEL=) || exit 1; \ done [src/util] for i in argv.h attr.h base64_code.h binhash.h chroot_uid.h clean_env.h connect.h ctable.h dict.h dict_db.h dict_dbm.h dict_env.h dict_cidr.h dict_ht.h dict_ni.h dict_nis.h dict_nisplus.h dict_pcre.h dict_regexp.h dict_static.h dict_tcp.h dict_unix.h dir_forest.h events.h exec_command.h find_inet.h fsspace.h fullname.h get_domainname.h get_hostname.h hex_quote.h host_port.h htable.h inet_addr_host.h inet_addr_list.h inet_addr_local.h inet_util.h iostuff.h line_wrap.h listen.h lstat_as.h mac_expand.h mac_parse.h make_dirs.h match_list.h match_ops.h msg.h msg_output.h msg_syslog.h msg_vstream.h mvect.h myflock.h mymalloc.h myrand.h name_mask.h netstring.h nvtable.h open_as.h open_lock.h percentm.h posix_signals.h readlline.h ring.h safe.h safe_open.h sane_accept.h sane_fsops.h sane_socketpair.h sane_time.h scan_dir.h set_eugid.h set_ugid.h sigdelay.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 auto_clnt.h attr_clnt.h sane_connect.h name_code.h; \ do \ cmp -s $i ../../include/$i 2>/dev/null || cp $i ../../include; \ done cd ../../include; chmod 644 argv.h attr.h base64_code.h binhash.h chroot_uid.h clean_env.h connect.h ctable.h dict.h dict_db.h dict_dbm.h dict_env.h dict_cidr.h dict_ht.h dict_ni.h dict_nis.h dict_nisplus.h dict_pcre.h dict_regexp.h dict_static.h dict_tcp.h dict_unix.h dir_forest.h events.h exec_command.h find_inet.h fsspace.h fullname.h get_domainname.h get_hostname.h hex_quote.h host_port.h htable.h inet_addr_host.h inet_addr_list.h inet_addr_local.h inet_util.h iostuff.h line_wrap.h listen.h lstat_as.h mac_expand.h mac_parse.h make_dirs.h match_list.h match_ops.h msg.h msg_output.h msg_syslog.h msg_vstream.h mvect.h myflock.h mymalloc.h myrand.h name_mask.h netstring.h nvtable.h open_as.h open_lock.h percentm.h posix_signals.h readlline.h ring.h safe.h safe_open.h sane_accept.h sane_fsops.h sane_socketpair.h sane_time.h scan_dir.h set_eugid.h set_ugid.h sigdelay.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 auto_clnt.h attr_clnt.h sane_connect.h name_code.h [src/global] for i in abounce.h been_here.h bounce.h bounce_log.h canon_addr.h cfg_parser.h cleanup_user.h clnt_stream.h config.h debug_peer.h debug_process.h defer.h deliver_completed.h deliver_flock.h deliver_pass.h deliver_request.h dict_ldap.h dict_mysql.h dict_pgsql.h dict_proxy.h domain_list.h dot_lockfile.h dot_lockfile_as.h ext_prop.h file_id.h flush_clnt.h header_opts.h header_token.h hold_message.h input_transp.h is_header.h lex_822.h log_adhoc.h mail_addr.h mail_addr_crunch.h mail_addr_find.h mail_addr_map.h mail_conf.h mail_copy.h mail_date.h mail_dict.h mail_error.h mail_flush.h mail_open_ok.h mail_params.h mail_proto.h mail_queue.h mail_run.h mail_scan_dir.h mail_stream.h mail_task.h mail_version.h maps.h mark_corrupt.h match_parent_style.h mbox_conf.h mbox_open.h mime_state.h mkmap.h mynetworks.h mypwd.h namadr_list.h off_cvt.h opened.h own_inet_addr.h pipe_command.h post_mail.h qmgr_user.h qmqp_proto.h quote_821_local.h quote_822_local.h quote_flags.h rec_streamlf.h rec_type.h recipient_list.h record.h resolve_clnt.h resolve_local.h rewrite_clnt.h sent.h smtp_stream.h split_addr.h string_list.h strip_addr.h sys_exits.h timed_ipc.h tok822.h trace.h verify.h verify_clnt.h verp_sender.h virtual8_maps.h xtext.h; \ do \ cmp -s $i ../../include/$i 2>/dev/null || cp $i ../../include; \ done cd ../../include; chmod 644 abounce.h been_here.h bounce.h bounce_log.h canon_addr.h cfg_parser.h cleanup_user.h clnt_stream.h config.h debug_peer.h debug_process.h defer.h deliver_completed.h deliver_flock.h deliver_pass.h deliver_request.h dict_ldap.h dict_mysql.h dict_pgsql.h dict_proxy.h domain_list.h dot_lockfile.h dot_lockfile_as.h ext_prop.h file_id.h flush_clnt.h header_opts.h header_token.h hold_message.h input_transp.h is_header.h lex_822.h log_adhoc.h mail_addr.h mail_addr_crunch.h mail_addr_find.h mail_addr_map.h mail_conf.h mail_copy.h mail_date.h mail_dict.h mail_error.h mail_flush.h mail_open_ok.h mail_params.h mail_proto.h mail_queue.h mail_run.h mail_scan_dir.h mail_stream.h mail_task.h mail_version.h maps.h mark_corrupt.h match_parent_style.h mbox_conf.h mbox_open.h mime_state.h mkmap.h mynetworks.h mypwd.h namadr_list.h off_cvt.h opened.h own_inet_addr.h pipe_command.h post_mail.h qmgr_user.h qmqp_proto.h quote_821_local.h quote_822_local.h quote_flags.h rec_streamlf.h rec_type.h recipient_list.h record.h resolve_clnt.h resolve_local.h rewrite_clnt.h sent.h smtp_stream.h split_addr.h string_list.h strip_addr.h sys_exits.h timed_ipc.h tok822.h trace.h verify.h verify_clnt.h verp_sender.h virtual8_maps.h xtext.h [src/dns] for i in dns.h; \ do \ cmp -s $i ../../include/$i 2>/dev/null || cp $i ../../include; \ done cd ../../include; chmod 644 dns.h [src/master] gcc -Wmissing-prototypes -Wformat -DHAS_MYSQL -I/usr/include/mysql -mcpu=i48 6 -fno-strength-reduce -DHAS_PCRE -g -O -I. -I../../include -DLINUX2 -o master master.o master_conf.o master_ent.o master_sig.o master_avail.o master_spawn.o master_service.o master_status.o master_listen.o master_vars.o master_wakeup.o master_flow.o ../../lib/libglobal.a ../../lib/libutil.a -L/usr/lib/mysql -lmysqlclient -lz -lcrypt -lnsl -lm -lc -lnss_files -lnss_dns -lresolv -lc -lnss_files -lnss_dns -lresolv -L/usr/li b -lpcre -ldb -lnsl -lresolv /usr/lib/gcc-lib/i486-suse-linux/3.2/../../../../i486-suse-linux/bin/ld: cannot find -lnss_files collect2: ld returned 1 exit status make: *** [master] Error 1 make: *** [update] Error 1 ------------ Thanks, --BobC