1
0

Makefile 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  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:= ppp
  5. PKG_VERSION:= 2.4.4
  6. PKG_RELEASE:= 16
  7. PKG_MD5SUM:= 183800762e266132218b204dfb428d29
  8. PKG_DESCR:= a PPP (Point-to-Point Protocol) software (with MPPE/MPPC support)
  9. PKG_SECTION:= net
  10. PKG_DEPENDS:= kmod-ppp
  11. PKG_URL:= http://ppp.samba.org
  12. PKG_SITES:= ftp://ftp.samba.org/pub/ppp/
  13. include ${TOPDIR}/mk/package.mk
  14. $(eval $(call PKG_template,PPP,${PKG_NAME},${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  15. $(eval $(call PKG_template,PPP_MOD_PPPOA,ppp-mod-pppoa,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  16. $(eval $(call PKG_template,PPP_MOD_PPPOE,ppp-mod-pppoe,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  17. $(eval $(call PKG_template,PPP_MOD_RADIUS,ppp-mod-radius,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  18. $(eval $(call PKG_template,PPP_MOD_CHAT,ppp-mod-chat,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  19. $(eval $(call PKG_template,PPP_MOD_PPPDUMP,ppp-mod-pppdump,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  20. $(eval $(call PKG_template,PPP_MOD_PPPSTATS,ppp-mod-pppstats,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  21. $(eval $(call PKG_template,PPP_MOD_PPPUMTS,ppp-mod-pppumts,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  22. ifeq ($(ADK_IPV6),y)
  23. IPV6+=HAVE_INET6="1"
  24. endif
  25. CONFIGURE_STYLE:= gnu
  26. BUILD_STYLE:= auto
  27. INSTALL_STYLE:= auto
  28. XAKE_FLAGS+= CC="${TARGET_CC}" \
  29. COPTS="${TCFLAGS}" \
  30. ${IPV6} \
  31. STAGING_DIR=${STAGING_DIR} \
  32. DESTDIR="${WRKINST}/usr" \
  33. TARGET_AR='${TARGET_CROSS}ar'
  34. SUB_INSTALLS-y:=
  35. SUB_INSTALLS-m:=
  36. SUB_INSTALLS-${ADK_PACKAGE_PPP_MOD_PPPOE}+= mod-pppoe-install
  37. SUB_INSTALLS-${ADK_PACKAGE_PPP_MOD_RADIUS}+= mod-radius-install
  38. SUB_INSTALLS-${ADK_PACKAGE_PPP_MOD_CHAT}+= mod-chat-install
  39. SUB_INSTALLS-${ADK_PACKAGE_PPP_MOD_PPPDUMP}+= mod-pppdump-install
  40. SUB_INSTALLS-${ADK_PACKAGE_PPP_MOD_PPPSTATS}+= mod-pppstats-install
  41. SUB_INSTALLS-${ADK_PACKAGE_PPP_MOD_PPPUMTS}+= mod-pppumts-install
  42. post-install: ${SUB_INSTALLS-m} ${SUB_INSTALLS-y}
  43. echo -------------------------------
  44. echo ${SUB_INSTALLS-m}
  45. echo ${SUB_INSTALLS-y}
  46. ${INSTALL_DIR} ${IDIR_PPP}/etc/ppp
  47. ln -sf /tmp/resolv.conf ${IDIR_PPP}/etc/ppp/resolv.conf
  48. install -m0600 ./files/etc/ppp/chap-secrets ${IDIR_PPP}/etc/ppp/
  49. ${INSTALL_DATA} ./files/etc/ppp/options ${IDIR_PPP}/etc/ppp/
  50. ${INSTALL_FILTER}
  51. ${INSTALL_BIN} ./files/etc/ppp/ip-up ${IDIR_PPP}/etc/ppp/
  52. ${INSTALL_DIR} ${IDIR_PPP}/etc/ppp/ip-up.d
  53. ${INSTALL_BIN} ./files/etc/ppp/ip-up.d/if-rename ${IDIR_PPP}/etc/ppp/ip-up.d/
  54. ${INSTALL_BIN} ./files/etc/ppp/ip-down ${IDIR_PPP}/etc/ppp/
  55. ${INSTALL_DIR} ${IDIR_PPP}/etc/ppp/ip-down.d
  56. ${INSTALL_DIR} ${IDIR_PPP}/usr/sbin
  57. ${INSTALL_BIN} ${WRKINST}/usr/sbin/pppd ${IDIR_PPP}/usr/sbin/
  58. ${INSTALL_DIR} ${IDIR_PPP}/usr/lib/pppd
  59. ${INSTALL_BIN} ./files/pon ${IDIR_PPP}/usr/sbin/
  60. ${INSTALL_BIN} ./files/poff ${IDIR_PPP}/usr/sbin/
  61. ${INSTALL_DIR} ${IDIR_PPP}/etc/ppp/peers
  62. ${INSTALL_DIR} ${IDIR_PPP}/etc/ppp/templates
  63. ${INSTALL_DATA} ./files/etc/ppp/templates/dsl ${IDIR_PPP}/etc/ppp/templates/
  64. mod-radius-install:
  65. ${INSTALL_DIR} ${IDIR_PPP_MOD_RADIUS}/etc/radiusclient
  66. ${CP} ${WRKBUILD}/pppd/plugins/radius/etc/* ${IDIR_PPP_MOD_RADIUS}/etc/radiusclient
  67. rm ${IDIR_PPP_MOD_RADIUS}/etc/radiusclient/radiusclient.conf.in
  68. ${INSTALL_DIR} ${IDIR_PPP_MOD_RADIUS}/usr/lib/pppd/$(PKG_VERSION)
  69. ${INSTALL_BIN} $(WRKINST)/usr/lib/pppd/$(PKG_VERSION)/radius.so \
  70. ${IDIR_PPP_MOD_RADIUS}/usr/lib/pppd/$(PKG_VERSION)
  71. mod-pppoe-install:
  72. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPOE}/usr/lib/pppd/$(PKG_VERSION)
  73. ${INSTALL_BIN} $(WRKINST)/usr/lib/pppd/$(PKG_VERSION)/rp-pppoe.so \
  74. ${IDIR_PPP_MOD_PPPOE}/usr/lib/pppd/$(PKG_VERSION)
  75. mod-chat-install:
  76. ${INSTALL_DIR} ${IDIR_PPP_MOD_CHAT}/usr/sbin
  77. ${CP} ${WRKINST}/usr/sbin/chat ${IDIR_PPP_MOD_CHAT}/usr/sbin/
  78. mod-pppdump-install:
  79. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPDUMP}/usr/sbin
  80. ${CP} ${WRKINST}/usr/sbin/pppdump ${IDIR_PPP_MOD_PPPDUMP}/usr/sbin/
  81. mod-pppstats-install:
  82. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPSTATS}/usr/sbin
  83. ${CP} ${WRKINST}/usr/sbin/pppstats ${IDIR_PPP_MOD_PPPSTATS}/usr/sbin/
  84. mod-pppumts-install:
  85. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPUMTS}/etc/ppp/templates
  86. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPUMTS}/etc/ppp/ip-{down,up}.d
  87. ${INSTALL_DATA} ./files/etc/ppp/templates/umts \
  88. ${IDIR_PPP_MOD_PPPUMTS}/etc/ppp/templates/
  89. ${INSTALL_BIN} ./files/etc/ppp/ip-up.d/umts \
  90. ${IDIR_PPP_MOD_PPPUMTS}/etc/ppp/ip-up.d/
  91. ${INSTALL_BIN} ./files/etc/ppp/ip-down.d/umts \
  92. ${IDIR_PPP_MOD_PPPUMTS}/etc/ppp/ip-down.d/
  93. include ${TOPDIR}/mk/pkg-bottom.mk