databases/soci: 3.2.2 -> 4.0.1

PR:		252784
Approved by:	jlaffaye (maintainer's timeout 18 days)
This commit is contained in:
Yuri Victorovich 2021-02-04 18:38:45 +00:00
parent 70b7a0b34f
commit b60cc71649
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=564057
8 changed files with 51 additions and 100 deletions

View file

@ -2,10 +2,8 @@
# $FreeBSD$
PORTNAME= soci
PORTVERSION= 3.2.2
PORTREVISION= 18
DISTVERSION= 4.0.1
CATEGORIES= databases
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION}
MAINTAINER= jlaffaye@FreeBSD.org
COMMENT= C++ Database Access Library
@ -13,10 +11,14 @@ COMMENT= C++ Database Access Library
LICENSE= BSL
LICENSE_FILE= ${WRKSRC}/LICENSE_1_0.txt
USES= cmake compiler:c++11-lang zip
CMAKE_ARGS+= -DWITH_ORACLE:BOOL=OFF
USES= cmake compiler:c++11-lang
USE_LDCONFIG= yes
USE_GITHUB= yes
GH_ACCOUNT= SOCI
CMAKE_OFF= WITH_ORACLE
SUB_FILES= pkg-message
OPTIONS_DEFINE= MYSQL PGSQL SQLITE ODBC BOOST FIREBIRD

View file

@ -1,2 +1,3 @@
SHA256 (soci-3.2.2.zip) = e3ad3ea0ef37eab0ae9e6459d2cdd099b1fa1165b663c349e1200356cf4e9c91
SIZE (soci-3.2.2.zip) = 518502
TIMESTAMP = 1610905825
SHA256 (SOCI-soci-4.0.1_GH0.tar.gz) = fa69347b1a1ef74450c0382b665a67bd6777cc7005bbe09726479625bcf1e29c
SIZE (SOCI-soci-4.0.1_GH0.tar.gz) = 489841

View file

@ -1,11 +1,11 @@
--- CMakeLists.txt.orig 2012-06-19 19:38:59.955809070 +0300
+++ CMakeLists.txt 2012-06-19 19:41:10.731806799 +0300
@@ -68,7 +68,7 @@ include(SociDependencies)
# Installation
#################################################################################
--- CMakeLists.txt.orig 2020-10-19 14:59:47 UTC
+++ CMakeLists.txt
@@ -134,7 +134,7 @@ set_property(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
###############################################################################
-if(APPLE OR CMAKE_SIZEOF_VOID_P EQUAL 4)
+if(APPLE OR CMAKE_SIZEOF_VOID_P EQUAL 4 OR CMAKE_SYSTEM_NAME STREQUAL "FreeBSD")
set(SOCI_LIBDIR "lib")
else()
set(SOCI_LIBDIR "lib64")
if(NOT DEFINED SOCI_LIBDIR)
- if(APPLE OR CMAKE_SIZEOF_VOID_P EQUAL 4)
+ if(APPLE OR CMAKE_SIZEOF_VOID_P EQUAL 4 OR CMAKE_SYSTEM_NAME STREQUAL "FreeBSD")
set(SOCI_LIBDIR "lib")
else()
set(SOCI_LIBDIR "lib64")

View file

@ -1,14 +0,0 @@
Patch obtained from upstream
https://github.com/SOCI/soci/commit/165737c4be7d6c9acde92610b92e8f42a4cfe933
--- backends/mysql/session.cpp.orig 2018-01-04 20:29:49 UTC
+++ backends/mysql/session.cpp
@@ -199,7 +199,7 @@ void parse_connect_string(const string &
throw soci_error(err);
}
*port = std::atoi(val.c_str());
- if (port < 0)
+ if (*port < 0)
{
throw soci_error(err);
}

View file

@ -1,11 +0,0 @@
--- ./backends/postgresql/statement.cpp.orig 2014-05-05 16:49:26.985995826 +0200
+++ ./backends/postgresql/statement.cpp 2014-05-05 16:46:18.049008548 +0200
@@ -453,7 +453,7 @@
// pointer to it, so we can't rely on implicit conversion here.
const char * const resultStr = PQcmdTuples(result_.get_result());
char * end;
- long long result = std::strtoll(resultStr, &end, 0);
+ long long result = strtoq(resultStr, &end, 0);
if (end != resultStr)
{
return result;

View file

@ -1,20 +0,0 @@
--- ./backends/sqlite3/standard-into-type.cpp.orig 2013-08-22 00:40:11.000000000 +0200
+++ ./backends/sqlite3/standard-into-type.cpp 2014-05-05 16:45:06.981013401 +0200
@@ -107,7 +107,7 @@
case x_long_long:
{
long long* dest = static_cast<long long*>(data_);
- *dest = std::strtoll(buf, NULL, 10);
+ *dest = strtoq(buf, NULL, 10);
}
break;
case x_unsigned_long_long:
@@ -136,7 +136,7 @@
rowid *rid = static_cast<rowid *>(data_);
sqlite3_rowid_backend *rbe = static_cast<sqlite3_rowid_backend *>(rid->get_backend());
- long long val = std::strtoll(buf, NULL, 10);
+ long long val = strtoq(buf, NULL, 10);
rbe->value_ = static_cast<unsigned long>(val);
}
break;

View file

@ -1,10 +0,0 @@
--- cmake/SociBackend.cmake.orig 2012-06-19 19:07:03.554808441 +0300
+++ cmake/SociBackend.cmake 2012-06-19 19:07:19.839807427 +0300
@@ -61,6 +61,7 @@ macro(soci_backend NAME)
string(TOUPPER "${dep}" DEPU)
list(APPEND THIS_BACKEND_DEPENDS_INCLUDE_DIRS ${${DEPU}_INCLUDE_DIR})
list(APPEND THIS_BACKEND_DEPENDS_INCLUDE_DIRS ${${DEPU}_INCLUDE_DIRS})
+ list(APPEND THIS_BACKEND_DEPENDS_INCLUDE_DIRS ${${DEPU}_INCLUDE_DIRECTORIES})
list(APPEND THIS_BACKEND_DEPENDS_LIBRARIES ${${DEPU}_LIBRARIES})
list(APPEND THIS_BACKEND_DEPENDS_DEFS -DHAVE_${DEPU}=1)
endif()

View file

@ -1,29 +1,32 @@
cmake/SOCI-%%CMAKE_BUILD_TYPE%%.cmake
cmake/SOCI.cmake
include/soci/backend-loader.h
include/soci/bind-values.h
include/soci/blob-exchange.h
include/soci/blob.h
%%BOOST%%include/soci/boost-fusion.h
%%BOOST%%include/soci/boost-gregorian-date.h
%%BOOST%%include/soci/boost-optional.h
%%BOOST%%include/soci/boost-tuple.h
include/soci/callbacks.h
include/soci/column-info.h
include/soci/connection-parameters.h
include/soci/connection-pool.h
include/soci/empty/soci-empty.h
include/soci/error.h
include/soci/exchange-traits.h
%%FIREBIRD%%include/soci/firebird/common.h
%%FIREBIRD%%include/soci/firebird/soci-firebird.h
include/soci/into-type.h
include/soci/into.h
%%MYSQL%%include/soci/mysql/common.h
include/soci/logger.h
%%MYSQL%%include/soci/mysql/soci-mysql.h
include/soci/noreturn.h
%%ODBC%%include/soci/odbc/soci-odbc.h
%%ODBC%%include/soci/odbc/utility.h
include/soci/once-temp-type.h
%%PGSQL%%include/soci/postgresql/common.h
%%PGSQL%%include/soci/postgresql/soci-postgresql.h
include/soci/query_transformation.h
include/soci/prepare-temp-type.h
include/soci/procedure.h
include/soci/query_transformation.h
include/soci/ref-counted-prepare-info.h
include/soci/ref-counted-statement.h
include/soci/row-exchange.h
@ -37,7 +40,6 @@ include/soci/soci-config.h
include/soci/soci-platform.h
include/soci/soci-simple.h
include/soci/soci.h
%%SQLITE%%include/soci/sqlite3/common.h
%%SQLITE%%include/soci/sqlite3/soci-sqlite3.h
include/soci/statement.h
include/soci/transaction.h
@ -45,6 +47,7 @@ include/soci/type-conversion-traits.h
include/soci/type-conversion.h
include/soci/type-holder.h
include/soci/type-ptr.h
include/soci/type-wrappers.h
include/soci/unsigned-types.h
include/soci/use-type.h
include/soci/use.h
@ -53,29 +56,29 @@ include/soci/values.h
include/soci/version.h
lib/libsoci_core.a
lib/libsoci_core.so
lib/libsoci_core.so.3.2
lib/libsoci_core.so.3.2.2
lib/libsoci_core.so.4.0
lib/libsoci_core.so.4.0.1
lib/libsoci_empty.a
lib/libsoci_empty.so
lib/libsoci_empty.so.3.2
lib/libsoci_empty.so.3.2.2
%%MYSQL%%lib/libsoci_mysql.a
%%MYSQL%%lib/libsoci_mysql.so
%%MYSQL%%lib/libsoci_mysql.so.3.2
%%MYSQL%%lib/libsoci_mysql.so.3.2.2
%%ODBC%%lib/libsoci_odbc.a
%%ODBC%%lib/libsoci_odbc.so
%%ODBC%%lib/libsoci_odbc.so.3.2
%%ODBC%%lib/libsoci_odbc.so.3.2.2
%%PGSQL%%lib/libsoci_postgresql.a
%%PGSQL%%lib/libsoci_postgresql.so
%%PGSQL%%lib/libsoci_postgresql.so.3.2
%%PGSQL%%lib/libsoci_postgresql.so.3.2.2
%%SQLITE%%lib/libsoci_sqlite3.a
%%SQLITE%%lib/libsoci_sqlite3.so
%%SQLITE%%lib/libsoci_sqlite3.so.3.2
%%SQLITE%%lib/libsoci_sqlite3.so.3.2.2
lib/libsoci_empty.so.4.0
lib/libsoci_empty.so.4.0.1
%%FIREBIRD%%lib/libsoci_firebird.a
%%FIREBIRD%%lib/libsoci_firebird.so
%%FIREBIRD%%lib/libsoci_firebird.so.3.2
%%FIREBIRD%%lib/libsoci_firebird.so.3.2.2
%%FIREBIRD%%lib/libsoci_firebird.so.4.0
%%FIREBIRD%%lib/libsoci_firebird.so.4.0.1
%%MYSQL%%lib/libsoci_mysql.a
%%MYSQL%%lib/libsoci_mysql.so
%%MYSQL%%lib/libsoci_mysql.so.4.0
%%MYSQL%%lib/libsoci_mysql.so.4.0.1
%%ODBC%%lib/libsoci_odbc.a
%%ODBC%%lib/libsoci_odbc.so
%%ODBC%%lib/libsoci_odbc.so.4.0
%%ODBC%%lib/libsoci_odbc.so.4.0.1
%%PGSQL%%lib/libsoci_postgresql.a
%%PGSQL%%lib/libsoci_postgresql.so
%%PGSQL%%lib/libsoci_postgresql.so.4.0
%%PGSQL%%lib/libsoci_postgresql.so.4.0.1
%%SQLITE%%lib/libsoci_sqlite3.a
%%SQLITE%%lib/libsoci_sqlite3.so
%%SQLITE%%lib/libsoci_sqlite3.so.4.0
%%SQLITE%%lib/libsoci_sqlite3.so.4.0.1