Hello,
I'm trying to compile Kamailio 4.2.3 on Debian 7.8 with db_unixodbc but the sql.h file can't be found.
I've used the following command to compile and install unixODBC.
tar -zxvf unixODBC-2.3.2.tar.gz && cd unixODBC-2.3.2 && ./configure --sysconfdir=/etc --prefix=/usr/local/unixODBC --disable-gui && make && make install
#####################: locate odbc_config /usr/local/unixODBC/bin/odbc_config /usr/src/unixODBC-2.3.2/exe/odbc_config
#####################: locate sql.h /usr/local/unixODBC/include/sql.h /usr/src/kamailio-4.2.3/modules/db_mysql/km_db_mysql.h /usr/src/kamailio-4.2.3/modules/db_postgres/pg_sql.h /usr/src/unixODBC-2.3.2/Drivers/Postgre7.1/isql.h /usr/src/unixODBC-2.3.2/Drivers/nn/isql.h /usr/src/unixODBC-2.3.2/Drivers/nn/nnsql.h /usr/src/unixODBC-2.3.2/exe/isql.h /usr/src/unixODBC-2.3.2/include/sql.h
Kamailio Compile Error CC (gcc) [M db_unixodbc.so] connection.o In file included from connection.c:34:0: connection.h:42:17: fatal error: sql.h: No such file or directory compilation terminated. make[1]: *** [connection.o] Error 1 make: *** [modules] Error 1
Modules.lst include_modules= carrierroute db_unixodbc dialog_ng lcr tls uuid
Removed these includes from the exclude_modules
Any ideas?
Grant,
You may need to add /usr/local/unixODBC/ to the header include path for this module compile, e.g. add -I/usr/local/unixODBC/ to the Makefile at the appropriate place.ers
-- Alex
Also, it may be needed to set the path to the libraries, not to get the missing symbols when starting kamailio with the module -- see modules/db_unixodbc/Makefile and adjust the values for DEFS and LIBS variables.
On the other hand, if you install unixodbc from the packages of OS distro, kamailio should be able to compile and link it with default options.
Cheers, Daniel
On 23/03/15 18:27, Alex Balashov wrote:
Grant,
You may need to add /usr/local/unixODBC/ to the header include path for this module compile, e.g. add -I/usr/local/unixODBC/ to the Makefile at the appropriate place.ers
-- Alex
Installed it using the packages from the OS and now it compiles just fine.
Thanks!
-----Original Message----- From: sr-users [mailto:sr-users-bounces@lists.sip-router.org] On Behalf Of Daniel-Constantin Mierla Sent: Monday, March 23, 2015 10:38 PM To: Kamailio (SER) - Users Mailing List Subject: Re: [SR-Users] Compiling with db_unixodbc
Also, it may be needed to set the path to the libraries, not to get the missing symbols when starting kamailio with the module -- see modules/db_unixodbc/Makefile and adjust the values for DEFS and LIBS variables.
On the other hand, if you install unixodbc from the packages of OS distro, kamailio should be able to compile and link it with default options.
Cheers, Daniel
On 23/03/15 18:27, Alex Balashov wrote:
Grant,
You may need to add /usr/local/unixODBC/ to the header include path for this module compile, e.g. add -I/usr/local/unixODBC/ to the Makefile at the appropriate place.ers
-- Alex
-- Daniel-Constantin Mierla http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda Kamailio World Conference, May 27-29, 2015 Berlin, Germany - http://www.kamailioworld.com
_______________________________________________ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users