2 # Copyright (C) 2009-2010 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
11 PKG_VERSION
:=4.7.25.NC
14 PKG_BUILD_DIR
:=$(BUILD_DIR
)/db-
$(PKG_VERSION
)
15 PKG_SOURCE
:=db-
$(PKG_VERSION
).
tar.gz
16 PKG_SOURCE_URL
:=http
://download.oracle.com
/berkeley-db
/
17 PKG_MD5SUM
:=073ab7f20d24b3872a51ca762f5090e7
20 PKG_LIBTOOL_PATHS
:=. build_unix
22 include $(INCLUDE_DIR
)/package.mk
24 define Package
/libdb47
28 TITLE
:=Berkeley DB library
(4.7)
29 URL
:=http
://www.sleepycat.com
/products
/db.shtml
32 define Package
/libdb47
/description
33 Berkeley DB library
(4.7).
36 define Build
/Configure
37 (cd
$(PKG_BUILD_DIR
)/build_unix
; rm -f config.cache
; \
38 $(TARGET_CONFIGURE_OPTS
) \
39 CFLAGS
="$(TARGET_CFLAGS)" \
40 CPPFLAGS
="$(TARGET_CPPFLAGS)" \
41 LDFLAGS
="$(TARGET_LDFLAGS)" \
43 --target
=$(GNU_TARGET_NAME
) \
44 --host
=$(GNU_TARGET_NAME
) \
45 --build
=$(GNU_HOST_NAME
) \
51 --datadir=/usr
/share \
52 --includedir=/usr
/include \
53 --infodir=/usr
/share
/info \
55 --libexecdir
=/usr
/lib \
56 --localstatedir
=/var \
57 --mandir=/usr
/share
/man \
61 $(DISABLE_LARGEFILE
) \
66 --with-mutex
=UNIX
/fcntl \
72 --enable-cryptography \
76 TARGET_CFLAGS
+= $(FPIC
)
79 $(MAKE
) -C
$(PKG_BUILD_DIR
)/build_unix \
80 DESTDIR
="$(PKG_INSTALL_DIR)" install
83 define Package
/libdb47
/install
84 $(INSTALL_DIR
) $(1)/usr
/lib
85 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libdb-
*.so
$(1)/usr
/lib
/
88 define Build
/InstallDev
89 $(INSTALL_DIR
) $(1)/usr
/include
90 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/db.h
$(1)/usr
/include/
91 $(INSTALL_DIR
) $(1)/usr
/lib
/
92 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libdb
*.
{a
,so
} $(1)/usr
/lib
95 $(eval
$(call BuildPackage
,libdb47
))