aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--main/db/APKBUILD34
-rw-r--r--main/db/atomic.patch20
2 files changed, 33 insertions, 21 deletions
diff --git a/main/db/APKBUILD b/main/db/APKBUILD
index a0c978af4e9..ce746403ad4 100644
--- a/main/db/APKBUILD
+++ b/main/db/APKBUILD
@@ -2,7 +2,7 @@
pkgname=db
pkgver=5.3.28
_ver=${pkgver}
-pkgrel=0
+pkgrel=1
pkgdesc="The Berkeley DB embedded database system"
url="https://www.oracle.com/technology/software/products/berkeley-db/index.html"
arch="all"
@@ -11,25 +11,19 @@ options="!check" # "check target not available"
depends=
makedepends=
subpackages="$pkgname-dev $pkgname-doc $pkgname-utils $pkgname-c++:cxx"
-# Patches were found here:
-# http://www.oracle.com/technology/products/berkeley-db/db/update/4.7.25/patch.4.7.25.html
source="https://download.oracle.com/berkeley-db/db-$pkgver.tar.gz
+ atomic.patch
"
-_builddir="$srcdir/db-$_ver"
+builddir="$srcdir/db-$_ver"
prepare() {
- cd "$_builddir"
- update_config_sub || return 1
+ cd "$builddir"
+ default_prepare
+ update_config_sub
}
build () {
- cd "$_builddir"
- for i in ../patch.*; do
- [ -r "$i" ] || continue
- msg "Applying $i..."
- patch -p0 < $i || return 1
- done
-
+ cd "$builddir"
cd build_unix
../dist/configure \
--build=$CBUILD \
@@ -39,14 +33,13 @@ build () {
--enable-compat185 \
--enable-shared \
--enable-cxx \
- --disable-static \
- || return 1
- make LIBSO_LIBS=-lpthread || return 1
+ --disable-static
+ make
}
package() {
- cd "$srcdir"/db-$_ver/build_unix
- make DESTDIR="$pkgdir" install || return 1
+ cd "$builddir"/build_unix
+ make DESTDIR="$pkgdir" install
mkdir -p "$pkgdir"/usr/share/doc
mv "$pkgdir"/usr/docs "$pkgdir"/usr/share/doc/$pkgname
@@ -68,6 +61,5 @@ cxx() {
mv "$pkgdir"/usr/lib/libdb_cxx*.so "$subpkgdir"/usr/lib/
}
-md5sums="b99454564d5b4479750567031d66fe24 db-5.3.28.tar.gz"
-sha256sums="e0a992d740709892e81f9d93f06daf305cf73fb81b545afe72478043172c3628 db-5.3.28.tar.gz"
-sha512sums="e91bbe550fc147a8be7e69ade86fdb7066453814971b2b0223f7d17712bd029a8eff5b2b6b238042ff6ec1ffa6879d44cb95c5645a922fee305c26c3eeaee090 db-5.3.28.tar.gz"
+sha512sums="e91bbe550fc147a8be7e69ade86fdb7066453814971b2b0223f7d17712bd029a8eff5b2b6b238042ff6ec1ffa6879d44cb95c5645a922fee305c26c3eeaee090 db-5.3.28.tar.gz
+e9fedc5b870b95fe772a8121fca8b3642327d960441fe40a1090375efd37eec397a508e6e9100c2817c02bb4380421eb8ea400aeb060fe46a8bdac83a1abfbeb atomic.patch"
diff --git a/main/db/atomic.patch b/main/db/atomic.patch
new file mode 100644
index 00000000000..438fa7eedd7
--- /dev/null
+++ b/main/db/atomic.patch
@@ -0,0 +1,20 @@
+--- a/src/dbinc/atomic.h 2013-03-12 14:07:22.000000000 -0400
++++ b/src/dbinc/atomic.h.change 2013-03-12 14:06:35.000000000 -0400
+@@ -144,7 +144,7 @@
+ #define atomic_inc(env, p) __atomic_inc(p)
+ #define atomic_dec(env, p) __atomic_dec(p)
+ #define atomic_compare_exchange(env, p, o, n) \
+- __atomic_compare_exchange((p), (o), (n))
++ __atomic_compare_exchange_db((p), (o), (n))
+ static inline int __atomic_inc(db_atomic_t *p)
+ {
+ int temp;
+@@ -176,7 +176,7 @@
+ * http://gcc.gnu.org/onlinedocs/gcc-4.1.0/gcc/Atomic-Builtins.html
+ * which configure could be changed to use.
+ */
+-static inline int __atomic_compare_exchange(
++static inline int __atomic_compare_exchange_db(
+ db_atomic_t *p, atomic_value_t oldval, atomic_value_t newval)
+ {
+ atomic_value_t was;