Bump version to 0.5.6, adding SQLite3 support.

OK landry@
This commit is contained in:
jeremy 2011-03-14 18:30:33 +00:00
parent 81a9edf0e1
commit d11c5fe334
9 changed files with 94 additions and 32 deletions

View File

@ -1,16 +1,17 @@
# $OpenBSD: Makefile,v 1.1.1.1 2010/12/20 17:39:55 jeremy Exp $
# $OpenBSD: Makefile,v 1.2 2011/03/14 18:30:33 jeremy Exp $
SHARED_ONLY= Yes
COMMENT= C++ database API
DISTNAME= deepfryed-dbicpp-74e3352
PKGNAME= dbic++-0.4.1
DISTNAME= deepfryed-dbicpp-g466860f
PKGNAME= dbic++-0.5.6
CATEGORIES= databases
HOMEPAGE= http://github.com/deepfryed/dbicpp
HOMEPAGE= https://github.com/deepfryed/dbicpp
SHARED_LIBS += dbdmysql 0.0 # 0.0
SHARED_LIBS += dbdpg 0.0 # 0.0
SHARED_LIBS += dbdmysql 1.0 # 0.0
SHARED_LIBS += dbdpg 1.0 # 0.0
SHARED_LIBS += dbdsqlite3 0.0 # 0.0
# MIT
PERMIT_PACKAGE_CDROM= Yes
@ -21,7 +22,7 @@ PERMIT_DISTFILES_FTP= Yes
# port-lib-depends-check says that e2fs-uuid and pcrecpp are
# Extra, but they are used in a .a file that doesn't have a
# .so shared library equivalent.
WANTLIB = e2fs-uuid m mysqlclient pcrecpp pq stdc++
WANTLIB = e2fs-uuid m mysqlclient pcrecpp pq stdc++ sqlite3
MASTER_SITES= http://www.bsdfrog.org/OpenBSD/distfiles/
@ -29,23 +30,23 @@ BUILD_DEPENDS= devel/cmake \
shells/bash
LIB_DEPENDS= mysql-client->=5:databases/mysql \
postgresql-client->=8.4:databases/postgresql \
sqlite3->=3.7:databases/sqlite3 \
devel/pcre \
sysutils/e2fsprogs
CONFIGURE_STYLE= none
WRKDIST= ${WRKDIR}/${PKGNAME}
WRKDIST= ${WRKDIR}/deepfryed-dbicpp-4fe45f7
post-extract:
cd ${WRKDIR} && mv ${DISTNAME} ${PKGNAME}
pre-configure:
${SUBST_CMD} ${WRKSRC}/{CMakeLists.txt,inc/dbic++.h,src/dbic++.cc,pkgconfig/dbic++.pc}
do-build:
cd ${WRKSRC} && ${SET_ENV} ${MAKE_ENV} bash build.sh
cd ${WRKSRC} && ${SET_ENV} ${MAKE_ENV} ${LOCALBASE}/bin/bash build.sh
do-install:
cd ${WRKSRC} && ${SET_ENV} ${MAKE_ENV} \
${SUDO} bash build.sh -i
${SUDO} ${LOCALBASE}/bin/bash build.sh -i
NO_REGRESS= Yes
.include <bsd.port.mk>

View File

@ -1,5 +1,5 @@
MD5 (deepfryed-dbicpp-74e3352.tar.gz) = MOrYbkql48TgMbiXqRZi1w==
RMD160 (deepfryed-dbicpp-74e3352.tar.gz) = AEeyOJEsE97/BvyALhpVSES32UY=
SHA1 (deepfryed-dbicpp-74e3352.tar.gz) = FYyvmJW4AYCgkcfzv6oPjLMR6v4=
SHA256 (deepfryed-dbicpp-74e3352.tar.gz) = gyHQgoe1nefuS6kj4GVSWVgoiKA39kqOqq3K1dEp108=
SIZE (deepfryed-dbicpp-74e3352.tar.gz) = 53133
MD5 (deepfryed-dbicpp-g466860f.tar.gz) = QXv1uOF2+rCF8Dkv6tdc5Q==
RMD160 (deepfryed-dbicpp-g466860f.tar.gz) = POt1CYLnCq2kLPcoEkXJzveX+f4=
SHA1 (deepfryed-dbicpp-g466860f.tar.gz) = 0X1uzAXgzX7JJ5eC3yBUA/zNVqc=
SHA256 (deepfryed-dbicpp-g466860f.tar.gz) = odddcJsbvgq7Ony1pfG+JcjhhjR9FvkXwwF4JWBAPNE=
SIZE (deepfryed-dbicpp-g466860f.tar.gz) = 55945

View File

@ -1,25 +1,33 @@
$OpenBSD: patch-CMakeLists_txt,v 1.1.1.1 2010/12/20 17:39:55 jeremy Exp $
--- CMakeLists.txt.orig Sun Oct 17 08:56:31 2010
+++ CMakeLists.txt Thu Oct 28 16:16:23 2010
$OpenBSD: patch-CMakeLists_txt,v 1.2 2011/03/14 18:30:33 jeremy Exp $
--- CMakeLists.txt.orig Wed Jan 12 18:27:58 2011
+++ CMakeLists.txt Wed Jan 19 11:05:22 2011
@@ -32,7 +32,7 @@ IF (PQ_FOUND)
TARGET_LINK_LIBRARIES(dbdpg ${PQ_LIBRARIES})
ENDIF()
- SET_TARGET_PROPERTIES(dbdpg PROPERTIES VERSION ${CMAKE_PG_VERSION} SOVERSION 1)
+ SET_TARGET_PROPERTIES(dbdpg PROPERTIES VERSION "${CMAKE_PG_VERSION}0.0")
+ SET_TARGET_PROPERTIES(dbdpg PROPERTIES VERSION "${CMAKE_PG_VERSION}${LIBdbdpg_VERSION}")
INSTALL(TARGETS dbdpg
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/dbic++
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/dbic++)
@@ -46,7 +46,7 @@ IF (MYSQL_FOUND)
@@ -47,7 +47,7 @@ IF (MYSQL_FOUND)
ELSE()
TARGET_LINK_LIBRARIES(dbdmysql ${MYSQL_LIBRARIES})
ENDIF()
- SET_TARGET_PROPERTIES(dbdmysql PROPERTIES VERSION ${CMAKE_MYSQL_VERSION} SOVERSION 1)
+ SET_TARGET_PROPERTIES(dbdmysql PROPERTIES VERSION "${CMAKE_MYSQL_VERSION}0.0")
+ SET_TARGET_PROPERTIES(dbdmysql PROPERTIES VERSION "${CMAKE_MYSQL_VERSION}${LIBdbdmysql_VERSION}")
INSTALL(TARGETS dbdmysql
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/dbic++
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/dbic++)
@@ -68,12 +68,12 @@ IF (DB2_FOUND)
@@ -62,19 +62,19 @@ IF (SQLITE3_FOUND)
ELSE()
TARGET_LINK_LIBRARIES(dbdsqlite3 ${SQLITE3_LIBRARIES})
ENDIF()
- SET_TARGET_PROPERTIES(dbdsqlite3 PROPERTIES VERSION ${CMAKE_SQLITE3_VERSION} SOVERSION 1)
+ SET_TARGET_PROPERTIES(dbdsqlite3 PROPERTIES VERSION "${CMAKE_SQLITE3_VERSION}${LIBdbdsqlite3_VERSION}")
INSTALL(TARGETS dbdsqlite3
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/dbic++
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/dbic++)
ENDIF()
ADD_EXECUTABLE(demo/demo src/examples/demo.cc)

View File

@ -1,6 +1,6 @@
$OpenBSD: patch-build_sh,v 1.1.1.1 2010/12/20 17:39:55 jeremy Exp $
--- build.sh.orig Sun Oct 17 08:56:31 2010
+++ build.sh Thu Oct 28 16:39:16 2010
$OpenBSD: patch-build_sh,v 1.2 2011/03/14 18:30:33 jeremy Exp $
--- build.sh.orig Wed Jan 12 18:27:58 2011
+++ build.sh Tue Jan 18 15:46:51 2011
@@ -88,12 +88,10 @@ _uninstall() {
}
@ -8,7 +8,7 @@ $OpenBSD: patch-build_sh,v 1.1.1.1 2010/12/20 17:39:55 jeremy Exp $
- _uninstall
cmake -DCMAKE_PG_VERSION=$PG_VERSION \
-DCMAKE_MYSQL_VERSION=$MYSQL_VERSION \
-DCMAKE_DB2_VERSION=$DB2_VERSION \
-DCMAKE_SQLITE3_VERSION=$SQLITE3_VERSION \
- -DCMAKE_INSTALL_PREFIX:PATH=/usr
- make
+ -DCMAKE_INSTALL_PREFIX:PATH=${LOCALBASE}

View File

@ -0,0 +1,12 @@
$OpenBSD: patch-inc_dbic++_h,v 1.1 2011/03/14 18:30:33 jeremy Exp $
--- inc/dbic++.h.orig Wed Jan 12 18:27:58 2011
+++ inc/dbic++.h Wed Jan 19 11:05:22 2011
@@ -31,7 +31,7 @@ namespace dbi {
#include "dbic++/container.h"
#include "dbic++/cpool.h"
-#define DEFAULT_DRIVER_PATH "/usr/lib/dbic++"
+#define DEFAULT_DRIVER_PATH "${LOCALBASE}/lib/dbic++"
#define DBI_TYPE_UNKNOWN 0
#define DBI_TYPE_INT 1

View File

@ -0,0 +1,9 @@
$OpenBSD: patch-pkgconfig_dbic++_pc,v 1.1 2011/03/14 18:30:33 jeremy Exp $
--- pkgconfig/dbic++.pc.orig Wed Jan 12 18:27:58 2011
+++ pkgconfig/dbic++.pc Wed Jan 19 11:05:22 2011
@@ -1,4 +1,4 @@
-prefix=/usr
+prefix=${LOCALBASE}
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include

View File

@ -0,0 +1,13 @@
$OpenBSD: patch-src_dbic++_cc,v 1.1 2011/03/14 18:30:33 jeremy Exp $
--- src/dbic++.cc.orig Wed Jan 12 18:27:58 2011
+++ src/dbic++.cc Wed Jan 19 11:06:17 2011
@@ -106,8 +106,7 @@ namespace dbi {
void initCheck(string driver_name) {
if (!drivers.size()) {
- dbiInitialize("./lib/dbic++");
- dbiInitialize();
+ dbiInitialize("${LOCALBASE}/lib/dbic++");
}
if (!drivers[driver_name])

View File

@ -0,0 +1,16 @@
$OpenBSD: patch-src_file_io_cc,v 1.1 2011/03/14 18:30:33 jeremy Exp $
--- src/file_io.cc.orig Wed Jan 12 18:27:58 2011
+++ src/file_io.cc Tue Jan 18 16:59:51 2011
@@ -44,10 +44,9 @@ namespace dbi {
char *buffer;
size_t size;
- size = getline(&buffer, &size, fp);
- if (size > 0) {
+ buffer = fgetln(fp, &size);
+ if (buffer != NULL && size > 0) {
line = string(buffer, size);
- free(buffer);
return true;
}

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST,v 1.1.1.1 2010/12/20 17:39:55 jeremy Exp $
@comment $OpenBSD: PLIST,v 1.2 2011/03/14 18:30:33 jeremy Exp $
include/dbic++/
include/dbic++.h
include/dbic++/abstract_handle.h
@ -7,19 +7,22 @@ include/dbic++/abstract_statement.h
include/dbic++/container.h
include/dbic++/cpool.h
include/dbic++/error.h
include/dbic++/file_io.h
include/dbic++/handle.h
include/dbic++/io.h
include/dbic++/io_filestream.h
include/dbic++/io_stream.h
include/dbic++/param.h
include/dbic++/query.h
include/dbic++/reactor.h
include/dbic++/result.h
include/dbic++/result_row.h
include/dbic++/result_row_hash.h
include/dbic++/socketinfo.h
include/dbic++/statement.h
include/dbic++/string_io.h
include/dbic++/util.h
lib/dbic++/
@lib lib/dbic++/libdbdmysql.so.${LIBdbdmysql_VERSION}
@lib lib/dbic++/libdbdpg.so.${LIBdbdpg_VERSION}
@lib lib/dbic++/libdbdsqlite3.so.${LIBdbdsqlite3_VERSION}
lib/libdbic++.a
lib/pkgconfig/dbic++.pc