Makefile 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include ${TOPDIR}/rules.mk
  4. PKG_NAME:= sqlite
  5. PKG_VERSION:= 3.7.5
  6. PKG_RELEASE:= 1
  7. PKG_MD5SUM:= a9604a82613ade2e7f4c303f233e477f
  8. PKG_DESCR:= embeddable SQL database (cli)
  9. PKG_SECTION:= db
  10. PKG_BUILDDEP:= ncurses readline
  11. PKG_URL:= http://www.sqlite.org/
  12. PKG_SITES:= http://www.sqlite.org/
  13. DISTFILES:= sqlite-autoconf-3070500.tar.gz
  14. WRKDIST= ${WRKDIR}/sqlite-autoconf-3070500
  15. PKG_SUBPKGS:= SQLITE_CLI LIBSQLITE LIBSQLITE_DEV
  16. PKGSD_LIBSQLITE:= sqlite library
  17. include ${TOPDIR}/mk/package.mk
  18. $(eval $(call PKG_template,LIBSQLITE,libsqlite,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_LIBSQLITE},${PKG_SECTION}))
  19. $(eval $(call PKG_template,LIBSQLITE_DEV,libsqlite-dev,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_LIBSQLITE},${PKG_SECTION}))
  20. $(eval $(call PKG_template,SQLITE_CLI,sqlite-cli,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  21. TARGET_CFLAGS:= $(filter-out -flto,$(TARGET_CFLAGS))
  22. CONFIGURE_ENV+= config_BUILD_CC="${CC_FOR_BUILD}" \
  23. config_BUILD_CFLAGS="${CFLAGS_FOR_BUILD}" \
  24. config_TARGET_CC="${TARGET_CC}" \
  25. config_TARGET_CFLAGS="${TARGET_CFLAGS}" \
  26. config_TARGET_READLINE_INC="-I${STAGING_TARGET_DIR}/usr/include" \
  27. config_TARGET_READLINE_LIBS="-L${STAGING_TARGET_DIR}/usr/lib -lreadline -lncurses"
  28. MAKE_FLAGS+= LIBPTHREAD=-lm
  29. TARGET_CPPFLAGS+= -DSQLITE_SECURE_DELETE=1 -DSQLITE_THREADSAFE=1 -DSQLITE_ENABLE_FTS3=1 -DSQLITE_ENABLE_UNLOCK_NOTIFY=1
  30. libsqlite-install:
  31. ${INSTALL_DIR} ${IDIR_LIBSQLITE}/usr/lib
  32. ${CP} ${WRKINST}/usr/lib/libsqlite3.so* ${IDIR_LIBSQLITE}/usr/lib
  33. sqlite-cli-install:
  34. ${INSTALL_DIR} ${IDIR_SQLITE_CLI}/usr/bin
  35. ${INSTALL_BIN} ${WRKINST}/usr/bin/sqlite3 ${IDIR_SQLITE_CLI}/usr/bin
  36. libsqlite-dev-install:
  37. ${INSTALL_DIR} ${IDIR_LIBSQLITE_DEV}/usr/lib/pkgconfig
  38. ${CP} ${WRKINST}/usr/lib/pkgconfig/*.pc \
  39. ${IDIR_LIBSQLITE_DEV}/usr/lib/pkgconfig
  40. ${INSTALL_DIR} ${IDIR_LIBSQLITE_DEV}/usr/include
  41. ${CP} ${WRKINST}/usr/include/* \
  42. ${IDIR_LIBSQLITE_DEV}/usr/include
  43. include ${TOPDIR}/mk/pkg-bottom.mk