[gdal-dev] Compiling gdal 2.4.4: "fatal error: mysql.h: No such file or directory"

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

[gdal-dev] Compiling gdal 2.4.4: "fatal error: mysql.h: No such file or directory"

aborruso
Hi,
I'm building gdal 2.4.4 on CentOS Linux release 7.7.1908.

When I run "./configure --with-mysql=/usr/bin/mysql" I have no error.

Than when I run make I have

"make[3]: Entering directory
`/var/regsic/apps/gdal-2.4.4/ogr/ogrsf_frmts/mysql'
/bin/sh /var/regsic/apps/gdal-2.4.4/libtool --mode=compile --silent
--tag=CXX g++ -std=c++11 -I/var/regsic/apps/gdal-2.4.4/port
-I/var/regsic/apps/gdal-2.4.4/gcore -I/var/regsic/apps/gdal-2.4.4/alg
-I/var/regsic/apps/gdal-2.4.4/ogr
-I/var/regsic/apps/gdal-2.4.4/ogr/ogrsf_frmts
-I/var/regsic/apps/gdal-2.4.4/gnm -I/var/regsic/apps/gdal-2.4.4/apps
-DHAVE_AVX_AT_COMPILE_TIME -DHAVE_SSSE3_AT_COMPILE_TIME
-DHAVE_SSE_AT_COMPILE_TIME -g -O2  -Wall -Wextra -Winit-self
-Wunused-parameter -Wformat -Werror=format-security -Wno-format-nonliteral
-Wlogical-op -Wshadow -Werror=vla -Wmissing-declarations -Wnon-virtual-dtor
-Woverloaded-virtual -fno-operator-names -Wzero-as-null-pointer-constant
-I.. -I../..   -DGNM_ENABLED -I/var/regsic/apps/gdal-2.4.4/port
-DGDAL_COMPILATION -c -o ../o/ogrmysqldriver.lo ogrmysqldriver.cpp
In file included from ogrmysqldriver.cpp:29:0:
ogr_mysql.h:47:19: fatal error: mysql.h: No such file or directory"

"mysql.h" is in "/usr/include/mysql/mysql.h" and I have installed
mariadb-devel.

How to solve it?

Thank you



--
Sent from: http://osgeo-org.1560.x6.nabble.com/GDAL-Dev-f3742093.html
_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: Compiling gdal 2.4.4: "fatal error: mysql.h: No such file or directory"

Sebastiaan Couwenberg
On 3/19/20 3:51 PM, aborruso wrote:
> When I run "./configure --with-mysql=/usr/bin/mysql" I have no error.

You need to supply the path to mysql-config:

 --with-mysql=ARG Include MySQL (ARG=path to mysql_config) [default=no]

Kind Regards,

Bas

--
 GPG Key ID: 4096R/6750F10AE88D4AF1
Fingerprint: 8182 DE41 7056 408D 6146  50D1 6750 F10A E88D 4AF1
_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: Compiling gdal 2.4.4: "fatal error: mysql.h: No such file or directory"

aborruso
Thank you very much Sebastiaan, it works



--
Sent from: http://osgeo-org.1560.x6.nabble.com/GDAL-Dev-f3742093.html
_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev