blob: ff47e5033eb0452ce3dc480972a4dd1da8fadb5f [file] [log] [blame]
Andrew Geissler7e0e3c02022-02-25 20:34:39 +00001DESCRIPTION = "The C++ Database Access Library"
2HOMEPAGE = "http://soci.sourceforge.net"
3LICENSE = "BSL-1.0"
4LIC_FILES_CHKSUM = "file://LICENSE_1_0.txt;md5=e4224ccaecb14d942c71d31bef20d78c"
5SECTION = "libs"
6DEPENDS = "boost"
7
8SRC_URI = "${SOURCEFORGE_MIRROR}/project/${BPN}/${BPN}/${BP}/${BP}.tar.gz"
9SRC_URI[sha256sum] = "615e5f7e4b52007f3a3b4050a99aadf6346b56b5098eb08b3a650836083c6a33"
10
11TESTCONFIG = '-DSOCI_TEST_EMPTY_CONNSTR="dummy" -DSOCI_TEST_SQLITE3_CONNSTR="test.db" \
12 -DSOCI_TEST_POSTGRESQL_CONNSTR:STRING="dbname=soci_test" \
13 -DSOCI_TEST_MYSQL_CONNSTR:STRING="db=soci_test user=oe password=oe"'
14
15OBASEDIR ?= "/opt/oracle"
16OINCDIR = "rdbms/public"
17OLIBDIR = "lib"
18
19PACKAGECONFIG[sqlite3] = "-DSOCI_SQLITE3=ON,-DSOCI_SQLITE3=OFF,sqlite3,"
20PACKAGECONFIG[mysql] = "-DSOCI_MYSQL=ON,-DSOCI_MYSQL=OFF,mariadb,"
21PACKAGECONFIG[postgresql] = "-DSOCI_POSTGRESQL=ON,-DSOCI_POSTGRESQL=OFF,postgresql,"
22PACKAGECONFIG[odbc] = "-DSOCI_ODBC=ON,-DSOCI_ODBC=OFF,,"
23PACKAGECONFIG[empty] = "-DSOCI_EMPTY=ON,-DSOCI_EMPTY=OFF,,"
24PACKAGECONFIG[oracle] = "-DWITH_ORACLE=ON --with-oracle-include=${OINCDIR} --with-oracle-lib=${OLIBDIR},-DWITH_ORACLE=OFF,,"
25PACKAGECONFIG[firebird] = "-DWITH_FIREBIRD=ON,-DWITH_FIREBIRD=OFF,,"
26PACKAGECONFIG[ptest] = "${TESTCONFIG},,,"
27
28# enable your backend by default we enable 'empty'
29PACKAGECONFIG ??= "empty"
30
31# Take the flags added by PACKAGECONFIG and pass them to cmake.
32EXTRA_OECMAKE = "${EXTRA_OECONF} -DSOCI_LIBDIR=${libdir}"
33DISABLE_STATIC = ""
34
35inherit dos2unix cmake
36
37PACKAGES += "${PN}-sqlite3 ${PN}-mysql ${PN}-postgresql ${PN}-odbc ${PN}-oracle"
38
39FILES:${PN}-sqlite3 = "${libdir}/lib${BPN}_sqlite3.so.*"
40FILES:${PN}-mysql = "${libdir}/lib${BPN}_mysql.so.*"
41FILES:${PN}-postgresql = "${libdir}/lib${BPN}_postgresql.so.*"
42FILES:${PN}-odbc = "${libdir}/lib${BPN}_odbc.so.*"
43FILES:${PN}-oracle = "${libdir}/lib${BPN}_oracle.so.*"