On Wednesday, 6 October 2004 05.12, Bob Carpenter wrote:
gcc -Wmissing-prototypes -Wformat -DHAS_MYSQL -I/usr/local/mysql/include/mys ql -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/local/mysql/lib/mysql -lmysqlclient -lz -lm -L/us r/lib -lpcre -ldb -lnsl -lresolv /usr/lib/gcc-lib/i486-suse-linux/3.2/../../../../i486-suse-linux/bin/ld: cannot find -ldb collect2: ld returned 1 exit status make: *** [master] Error 1 make: *** [update] Error 1 ------------
I'm trying to build postfix with MySQL support, so I used this make:
make -f Makefile.init makefiles \ 'CCARGS=-DHAS_MYSQL -I/usr/local/mysql/include' \ 'AUXLIBS=-L/usr/local/mysql/lib -lmysqlclient -lz -lm'
One problem I had was <db.h> not found, so I added the following sym link to /usr/include: ln -s /usr/include/db2/db.h db.h
Better to add -I/usr/include/db2 to the flags but are you really sure you want to be using db2? I suspect that what you want to do instead of this is to make sure the packages db and db-devel are installed. I wonder if that won't cure the missing lib as well