James Freire
2004-Jul-28 06:23 UTC
[Asterisk-Users] Trouble compiling asterisk-addons MySQL
Hi All, I am having trouble compiling the mysql addon for asterisk. I had downloaded the most recent version from CVS and placed it in /usr/src/ and I get the following error below. root@linux2:/usr/src/asterisk-addons# make install ./mkdep -fPIC -I../asterisk -D_GNU_SOURCE `ls *.c` cdr_addon_mysql.c:33:19: mysql.h: No such file or directory cdr_addon_mysql.c:34:20: errmsg.h: No such file or directory for x in ; do install -m 755 $x /usr/lib/asterisk/modules ; done BTW. I have asterisk running just fine. Thanks, James -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20040728/194dcdb7/attachment.htm
Kannaiyan Natesan
2004-Jul-28 06:38 UTC
[Asterisk-Users] Trouble compiling asterisk-addons MySQL
Trouble compiling asterisk-addons MySQLDid you check whether mysql client libraries and headers were installed? -Kannaiyan http://www.goods2world.com - Your VoIP Shop ----- Original Message ----- From: James Freire To: asterisk-users@lists.digium.com Sent: Wednesday, July 28, 2004 2:23 PM Subject: [Asterisk-Users] Trouble compiling asterisk-addons MySQL Hi All, I am having trouble compiling the mysql addon for asterisk. I had downloaded the most recent version from CVS and placed it in /usr/src/ and I get the following error below. root@linux2:/usr/src/asterisk-addons# make install ./mkdep -fPIC -I../asterisk -D_GNU_SOURCE `ls *.c` cdr_addon_mysql.c:33:19: mysql.h: No such file or directory cdr_addon_mysql.c:34:20: errmsg.h: No such file or directory for x in ; do install -m 755 $x /usr/lib/asterisk/modules ; done BTW. I have asterisk running just fine. Thanks, James -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20040728/95856a84/attachment.htm
Oleg A. Arkhangelsky
2004-Jul-28 06:48 UTC
[Asterisk-Users] Trouble compiling asterisk-addons MySQL
Hello James, Wednesday, July 28, 2004, 5:23:16 PM, you wrote: JF> root@linux2:/usr/src/asterisk-addons# make install JF> ./mkdep -fPIC -I../asterisk -D_GNU_SOURCE `ls *.c` JF> cdr_addon_mysql.c:33:19: mysql.h: No such file or directory JF> cdr_addon_mysql.c:34:20: errmsg.h: No such file or directory JF> for x in ; do install -m 755 $x /usr/lib/asterisk/modules ; done You need to install libmysqlclient-devel (or alike) package with relevant header files. -- Best regards, Oleg mailto:sysoleg@progtech.ru
James Freire
2004-Jul-28 06:57 UTC
[Asterisk-Users] Trouble compiling asterisk-addons MySQL
Well. I have seemed to get a little farther with the problem. I added in a line in to the Makefile of CFLAGS+=-I/usr/local/mysql/include/mysql Now I get an error that has to do with mysqlclient below... I have also included my entire Makefile below the error. Thanks root@linux2:/usr/src/asterisk-addons# make install ./mkdep -fPIC -I../asterisk -I/usr/local/mysql/include/mysql -D_GNU_SOURCE -I/usr/local/mysql/include `ls *.c` cc -fPIC -I../asterisk -I/usr/local/mysql/include/mysql -D_GNU_SOURCE -I/usr/local/mysql/include -c -o cdr_addon_mysql.o cdr_addon_mysql.c cc -shared -Xlinker -x -o cdr_addon_mysql.so cdr_addon_mysql.o -lmysqlclient -lz -L/usr/local/mysql/lib /usr/lib/gcc-lib/i486-slackware-linux/3.2.3/../../../../i486-slackware-linux/bin/ld: cannot find -lmysqlclient collect2: ld returned 1 exit status make: *** [cdr_addon_mysql.so] Error 1 # # Asterisk -- A telephony toolkit for Linux. # # Makefile for CDR backends (dynamically loaded) # # Copyright (C) 1999, Mark Spencer # # Mark Spencer <markster@linux-support.net> # # This program is free software, distributed under the terms of # the GNU General Public License # MODS CFLAGS+=-fPIC CFLAGS+=-I../asterisk CFLAGS+=-I/usr/local/mysql/include/mysql CFLAGS+=-D_GNU_SOURCE INSTALL=install INSTALL_PREFIXASTLIBDIR=$(INSTALL_PREFIX)/usr/lib/asterisk MODULES_DIR=$(ASTLIBDIR)/modules # # MySQL stuff... Autoconf anyone?? # MODS+=$(shell if [ -d /usr/local/mysql/include/mysql ] || [ -d /usr/include/mysql ] || [ -d /usr /local/include/mysql ] || [ -d /opt/mysql/include ]; then echo "cdr_addon_mysql.so"; fi) CFLAGS+=$(shell if [ -d /usr/local/mysql/include/mysql ]; then echo "-I/usr/local/mysql/include" ; fi) CFLAGS+=$(shell if [ -d /usr/include/mysql ]; then echo "-I/usr/include/mysql"; fi) CFLAGS+=$(shell if [ -d /usr/local/include/mysql ]; then echo "-I/usr/local/include/mysql"; fi) CFLAGS+=$(shell if [ -d /opt/mysql/include/mysql ]; then echo "-I/opt/mysql/include/mysql"; fi) MLFLAGSMLFLAGS+=$(shell if [ -d /usr/lib/mysql ]; then echo "-L/usr/lib/mysql"; fi) MLFLAGS+=$(shell if [ -d /usr/local/mysql/lib ]; then echo "-L/usr/local/mysql/lib"; fi) MLFLAGS+=$(shell if [ -d /usr/local/lib/mysql ]; then echo "-L/usr/local/lib/mysql"; fi) MLFLAGS+=$(shell if [ -d /opt/mysql/lib/mysql ]; then echo "-L/opt/mysql/lib/mysql"; fi) all: depend $(MODS) install: all for x in $(MODS); do $(INSTALL) -m 755 $$x $(MODULES_DIR) ; done clean: rm -f *.so *.o .depend %.so : %.o $(CC) -shared -Xlinker -x -o $@ $< ifneq ($(wildcard .depend),) include .depend endif cdr_addon_mysql.so: cdr_addon_mysql.o $(CC) -shared -Xlinker -x -o $@ $< -lmysqlclient -lz $(MLFLAGS) depend: .depend .depend: ./mkdep $(CFLAGS) `ls *.c` -----Original Message----- From: Oleg A. Arkhangelsky [mailto:sysoleg@progtech.ru] Sent: Wednesday, July 28, 2004 9:48 AM To: asterisk-users-admin@lists.digium.com; James Freire Cc: asterisk-users@lists.digium.com Subject: Re: [Asterisk-Users] Trouble compiling asterisk-addons MySQL Hello James, Wednesday, July 28, 2004, 5:23:16 PM, you wrote: JF> root@linux2:/usr/src/asterisk-addons# make install JF> ./mkdep -fPIC -I../asterisk -D_GNU_SOURCE `ls *.c` JF> cdr_addon_mysql.c:33:19: mysql.h: No such file or directory JF> cdr_addon_mysql.c:34:20: errmsg.h: No such file or directory JF> for x in ; do install -m 755 $x /usr/lib/asterisk/modules ; done You need to install libmysqlclient-devel (or alike) package with relevant header files. -- Best regards, Oleg mailto:sysoleg@progtech.ru
James Freire
2004-Jul-28 07:57 UTC
[Asterisk-Users] Trouble compiling asterisk-addons MySQL
Yep.. I already have the headers and required files. Here is what I am getting now with my Make file also below it. root@linux2:/usr/src/asterisk-addons# make install ./mkdep -fPIC -I../asterisk -I/usr/local/mysql/include/mysql -D_GNU_SOURCE -I/usr/local/mysql/include `ls *.c` cc -fPIC -I../asterisk -I/usr/local/mysql/include/mysql -D_GNU_SOURCE -I/usr/local/mysql/include -c -o cdr_addon_mysql.o cdr_addon_mysql.c cc -shared -Xlinker -x -o cdr_addon_mysql.so cdr_addon_mysql.o -lmysqlclient -lz -L/usr/local/mysql/lib /usr/lib/gcc-lib/i486-slackware-linux/3.2.3/../../../../i486-slackware-linux/bin/ld: cannot find -lmysqlclient collect2: ld returned 1 exit status make: *** [cdr_addon_mysql.so] Error 1 # # Asterisk -- A telephony toolkit for Linux. # # Makefile for CDR backends (dynamically loaded) # # Copyright (C) 1999, Mark Spencer # # Mark Spencer <markster@linux-support.net> # # This program is free software, distributed under the terms of # the GNU General Public License # MODS CFLAGS+=-fPIC CFLAGS+=-I../asterisk CFLAGS+=-I/usr/local/mysql/include/mysql CFLAGS+=-D_GNU_SOURCE INSTALL=install INSTALL_PREFIXASTLIBDIR=$(INSTALL_PREFIX)/usr/lib/asterisk MODULES_DIR=$(ASTLIBDIR)/modules # # MySQL stuff... Autoconf anyone?? # MODS+=$(shell if [ -d /usr/local/mysql/include/mysql ] || [ -d /usr/include/mysql ] || [ -d /usr /local/include/mysql ] || [ -d /opt/mysql/include ]; then echo "cdr_addon_mysql.so"; fi) CFLAGS+=$(shell if [ -d /usr/local/mysql/include/mysql ]; then echo "-I/usr/local/mysql/include" ; fi) CFLAGS+=$(shell if [ -d /usr/include/mysql ]; then echo "-I/usr/include/mysql"; fi) CFLAGS+=$(shell if [ -d /usr/local/include/mysql ]; then echo "-I/usr/local/include/mysql"; fi) CFLAGS+=$(shell if [ -d /opt/mysql/include/mysql ]; then echo "-I/opt/mysql/include/mysql"; fi) MLFLAGSMLFLAGS+=$(shell if [ -d /usr/lib/mysql ]; then echo "-L/usr/lib/mysql"; fi) MLFLAGS+=$(shell if [ -d /usr/local/mysql/lib ]; then echo "-L/usr/local/mysql/lib"; fi) MLFLAGS+=$(shell if [ -d /usr/local/lib/mysql ]; then echo "-L/usr/local/lib/mysql"; fi) MLFLAGS+=$(shell if [ -d /opt/mysql/lib/mysql ]; then echo "-L/opt/mysql/lib/mysql"; fi) all: depend $(MODS) install: all for x in $(MODS); do $(INSTALL) -m 755 $$x $(MODULES_DIR) ; done clean: rm -f *.so *.o .depend %.so : %.o $(CC) -shared -Xlinker -x -o $@ $< ifneq ($(wildcard .depend),) include .depend endif cdr_addon_mysql.so: cdr_addon_mysql.o $(CC) -shared -Xlinker -x -o $@ $< -lmysqlclient -lz $(MLFLAGS) depend: .depend .depend: ./mkdep $(CFLAGS) `ls *.c` -----Original Message----- From: asterisk-users-admin@lists.digium.com [mailto:asterisk-users-admin@lists.digium.com]On Behalf Of Oleg A. Arkhangelsky Sent: Wednesday, July 28, 2004 9:48 AM To: asterisk-users-admin@lists.digium.com; James Freire Cc: asterisk-users@lists.digium.com Subject: Re: [Asterisk-Users] Trouble compiling asterisk-addons MySQL Hello James, Wednesday, July 28, 2004, 5:23:16 PM, you wrote: JF> root@linux2:/usr/src/asterisk-addons# make install JF> ./mkdep -fPIC -I../asterisk -D_GNU_SOURCE `ls *.c` JF> cdr_addon_mysql.c:33:19: mysql.h: No such file or directory JF> cdr_addon_mysql.c:34:20: errmsg.h: No such file or directory JF> for x in ; do install -m 755 $x /usr/lib/asterisk/modules ; done You need to install libmysqlclient-devel (or alike) package with relevant header files. -- Best regards, Oleg mailto:sysoleg@progtech.ru _______________________________________________ Asterisk-Users mailing list Asterisk-Users@lists.digium.com http://lists.digium.com/mailman/listinfo/asterisk-users To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Hello all, I receive a warning message every time I start my Asterisk. Rate not correct, requested 8000, got 7999 I see in the source and FOUND where is gerating this warning message. if (rate != DESIRED_RATE) { ast_log(LOG_WARNING, "Rate not correct, requested %d, got %d\n", DESIRED_RATE, rate); } Anyone know HOW TO FIX this problem? -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20040728/e820d453/attachment.htm