1 # --- T2-COPYRIGHT-NOTE-BEGIN ---
2 # T2 SDE: package/*/bdb/bdb-conf.in
3 # Copyright (C) 2004 - 2021 The T2 SDE Project
4 # Copyright (C) 1998 - 2003 ROCK Linux Project
6 # This Copyright note is generated by scripts/Create-CopyPatch,
7 # more information can be found in the files COPYING and README.
9 # This program is free software; you can redistribute it and/or modify
10 # it under the terms of the GNU General Public License version 2.
11 # --- T2-COPYRIGHT-NOTE-END ---
16 for x in `match_source_file -p patch ${pkg%-java}`; do
20 hook_add prepatch 5 'bdb_autopatch'
22 hook_add preconf 5 'cd build_unix'
23 configscript="../dist/configure"
25 # explicitly link to pthread (required for --as-needed)
26 var_append GCC_WRAPPER_APPEND ' ' "-lpthread"
28 if [[ $pkg = *-java ]]; then
29 pkgprefix -t java-dirtree
30 prefix=$( pkgprefix java-dirtree )
33 var_append confopt ' ' '--enable-java'
35 libjso_base=libdb_java
38 # bdb doesn't like some of our make options
39 makeopt="libj_jarfile=$libjso_base-${libversion}.jar"
40 makeinstopt="$makeopt"
42 var_append makeinstopt ' ' install_lib
43 var_append makeinstopt ' ' "install_docs docdir=$docdir DOCLIST=java"
45 var_append makeopt ' ' $libjso_base-${libversion}.la
46 var_append makeopt ' ' java
48 var_append confopt ' ' '--enable-compat185'
49 var_append confopt ' ' '--enable-cxx'
50 var_append confopt ' ' '--enable-dbm'
52 # we need the install-sh here, since our gnu-install does not
53 # handle the transform-name ...
54 var_append confopt ' ' "--program-transform-name='s/db/db${ver:0:1}/'"
56 # bdb doesn't like some of our make options
57 makeopt="docdir=$docdir -j$SDECFG_PARALLEL_MAX all"
58 makeinstopt="docdir=$docdir install"
60 # create yet another alternative library name some programs use
61 # this will crate a symlink in the form libdb-4.1.so -> libdb41.so
62 hook_add postinstall 9 'ln -sfv libdb-${ver:0:3}.so $root$libdir/libdb${ver:0:1}.so'
65 includedir=$includedir/db${ver:0:1}
67 # bdb does copy the docs itself ...
70 var_append makeinstopt ' ' "DESTDIR=$root"