Makefile 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  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:= ncurses
  5. PKG_VERSION:= 5.7
  6. PKG_RELEASE:= 4
  7. PKG_MD5SUM:= cce05daf61a64501ef6cd8da1f727ec6
  8. PKG_DESCR:= a terminal handling library
  9. PKG_SECTION:= libs
  10. PKG_URL:= http://www.gnu.org/software/ncurses/
  11. PKG_SITES:= ${MASTER_SITE_GNU:=ncurses/}
  12. PKG_SUBPKGS:= LIBNCURSES LIBNCURSES_DEV
  13. PKGSD_LIBNCURSES_DEV:= development files for libncurses
  14. PKGSC_LIBNCURSES_DEV:= devel
  15. PKG_FLAVOURS_LIBNCURSES:= FULL_TERMINFO
  16. PKGFD_FULL_TERMINFO:= install the complete set of terminfo files as provided upstream
  17. include ${TOPDIR}/mk/package.mk
  18. $(eval $(call PKG_template,LIBNCURSES,libncurses,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  19. $(eval $(call PKG_template,LIBNCURSES_DEV,libncurses-dev,${PKG_VERSION}-${PKG_RELEASE},libncurses,${PKGSD_LIBNCURSES_DEV},${PKGSC_LIBNCURSES_DEV}))
  20. TARGET_CFLAGS+= -lgcc
  21. CONFIGURE_ENV+= ac_cv_linux_vers=2
  22. CONFIGURE_ARGS+= --without-cxx \
  23. --without-cxx-binding \
  24. --with-build-cc=${CC_FOR_BUILD} \
  25. --without-progs \
  26. --with-fallbacks \
  27. --disable-termcap \
  28. --without-ada \
  29. --with-shared \
  30. --with-normal \
  31. --without-debug \
  32. --without-profile \
  33. --without-gpm \
  34. --enable-overwrite \
  35. --with-terminfo-dirs=/usr/share/terminfo \
  36. --with-default-terminfo-dir=/usr/share/terminfo \
  37. --disable-big-core \
  38. --disable-home-terminfo \
  39. --without-rcs-ids \
  40. --enable-const \
  41. --enable-echo
  42. ALL_TARGET:= libs
  43. INSTALL_TARGET:= install.libs install.data
  44. pre-configure:
  45. # create tic host binary
  46. (cd ${WRKBUILD}; rm -rf config.{cache,status} ; \
  47. ./configure \
  48. --with-shared \
  49. --with-build-cc=${CC_FOR_BUILD} \
  50. --with-progs \
  51. --without-debug \
  52. --without-profile \
  53. );
  54. ${MAKE} -C ${WRKBUILD}/include
  55. ${MAKE} -C ${WRKBUILD}/progs
  56. ${CP} ${WRKBUILD}/progs/tic ${STAGING_HOST_DIR}/bin
  57. find ${WRKBUILD} -name *.o -exec rm {} \;
  58. find ${WRKBUILD} -name *.a -exec rm {} \;
  59. libncurses-install:
  60. # this is installed as libncurses - make libcurses a "link"
  61. rm -f ${WRKINST}/usr/lib/libcurses.so*
  62. echo 'GROUP(-lncurses)' >${WRKINST}/usr/lib/libcurses.so
  63. # libcurses will not show up in the IPKG, only in STAGING_TARGET_DIR
  64. ${INSTALL_DIR} ${IDIR_LIBNCURSES}/usr/lib
  65. ${CP} ${WRKINST}/usr/lib/lib{form,menu,ncurses,panel}.so* \
  66. ${IDIR_LIBNCURSES}/usr/lib
  67. ifeq (${ADK_PACKAGE_LIBNCURSES_FULL_TERMINFO},y)
  68. ${INSTALL_DIR} ${IDIR_LIBNCURSES}/usr/share
  69. ${CP} ${WRKINST}/usr/share/terminfo ${IDIR_LIBNCURSES}/usr/share/
  70. else
  71. ${INSTALL_DIR} ${IDIR_LIBNCURSES}/usr/share/terminfo/
  72. for f in ansi dumb linux screen vt100 vt102 \
  73. rxvt-unicode vt220 xterm xterm-color xterm-xfree86; do \
  74. ${INSTALL_DIR} ${IDIR_LIBNCURSES}/usr/share/terminfo/$${f:0:1}; \
  75. ${INSTALL_DATA} ${WRKINST}/usr/share/terminfo/*/$$f \
  76. ${IDIR_LIBNCURSES}/usr/share/terminfo/$${f:0:1}/$$f; \
  77. done
  78. endif
  79. libncurses-dev-install:
  80. ${INSTALL_DIR} ${IDIR_LIBNCURSES_DEV}/usr/include
  81. ${CP} ${WRKINST}/usr/include/*.h ${IDIR_LIBNCURSES_DEV}/usr/include
  82. ${INSTALL_DIR} ${IDIR_LIBNCURSES_DEV}/usr/bin
  83. ${INSTALL_BIN} ${WRKINST}/usr/bin/ncurses5-config \
  84. ${IDIR_LIBNCURSES_DEV}/usr/bin
  85. include ${TOPDIR}/mk/pkg-bottom.mk