Makefile 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  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.5
  6. PKG_RELEASE:= 5
  7. PKG_MD5SUM:= 4621bc56167b6953ec4071043fe0ec57
  8. PKG_DESCR:= Point-to-Point Protocol software
  9. PKG_SECTION:= ppp
  10. PKG_DEPENDS:= kmod-ppp
  11. PKG_URL:= http://ppp.samba.org/
  12. PKG_SITES:= ftp://ftp.samba.org/pub/ppp/
  13. PKG_MULTI:= 1
  14. PKG_SUBPKGS:= PPP PPP_MOD_PPPOA PPP_MOD_PPPOE PPP_MOD_RADIUS
  15. PKG_SUBPKGS+= PPP_MOD_CHAT PPP_MOD_PPPDUMP PPP_MOD_PPPSTATS PPP_MOD_PPPUMTS
  16. PKG_DEPENDS_PPPOE:= kmod-pppoe
  17. PKG_DEPENDS_UMTS:= comgt
  18. include ${TOPDIR}/mk/package.mk
  19. $(eval $(call PKG_template,PPP,${PKG_NAME},${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  20. $(eval $(call PKG_template,PPP_MOD_PPPOA,ppp-mod-pppoa,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  21. $(eval $(call PKG_template,PPP_MOD_PPPOE,ppp-mod-pppoe,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS_PPPOE},${PKG_DESCR},${PKG_SECTION}))
  22. $(eval $(call PKG_template,PPP_MOD_RADIUS,ppp-mod-radius,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  23. $(eval $(call PKG_template,PPP_MOD_CHAT,ppp-mod-chat,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  24. $(eval $(call PKG_template,PPP_MOD_PPPDUMP,ppp-mod-pppdump,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  25. $(eval $(call PKG_template,PPP_MOD_PPPSTATS,ppp-mod-pppstats,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  26. $(eval $(call PKG_template,PPP_MOD_PPPUMTS,ppp-mod-pppumts,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS_UMTS},${PKG_DESCR},${PKG_SECTION}))
  27. CONFIGURE_ENV+= UNAME_S="Linux"
  28. XAKE_FLAGS+= CC="${TARGET_CC}" \
  29. COPTS="${TCFLAGS}" \
  30. STAGING_TARGET_DIR=${STAGING_TARGET_DIR} \
  31. DESTDIR="${WRKINST}/usr" \
  32. TARGET_AR='${TARGET_CROSS}ar'
  33. SUB_INSTALLS-y:=
  34. SUB_INSTALLS-m:=
  35. SUB_INSTALLS-${ADK_PACKAGE_PPP_MOD_PPPOE}+= mod-pppoe-install
  36. SUB_INSTALLS-${ADK_PACKAGE_PPP_MOD_PPPOA}+= mod-pppoa-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. ${INSTALL_DIR} ${IDIR_PPP}/etc/ppp
  44. install -m0600 ./files/etc/ppp/chap-secrets ${IDIR_PPP}/etc/ppp/
  45. ${INSTALL_DATA} ./files/etc/ppp/options ${IDIR_PPP}/etc/ppp/
  46. ${INSTALL_BIN} ./files/etc/ppp/ip-up ${IDIR_PPP}/etc/ppp/
  47. ${INSTALL_DIR} ${IDIR_PPP}/etc/ppp/ip-up.d
  48. ${INSTALL_BIN} ./files/etc/ppp/ip-up.d/0* \
  49. ${IDIR_PPP}/etc/ppp/ip-up.d
  50. ${INSTALL_BIN} ./files/etc/ppp/ip-down ${IDIR_PPP}/etc/ppp/
  51. ${INSTALL_DIR} ${IDIR_PPP}/etc/ppp/ip-down.d
  52. ${INSTALL_BIN} ./files/etc/ppp/ip-down.d/0* \
  53. ${IDIR_PPP}/etc/ppp/ip-down.d
  54. ${INSTALL_DIR} ${IDIR_PPP}/usr/sbin
  55. ${INSTALL_BIN} ${WRKINST}/usr/sbin/pppd ${IDIR_PPP}/usr/sbin/
  56. ${INSTALL_DIR} ${IDIR_PPP}/usr/lib/pppd
  57. ${INSTALL_BIN} ./files/pon ${IDIR_PPP}/usr/sbin/
  58. ${INSTALL_BIN} ./files/poff ${IDIR_PPP}/usr/sbin/
  59. ${INSTALL_DIR} ${IDIR_PPP}/etc/ppp/peers
  60. $(INSTALL_DIR) ${IDIR_PPP}/etc/network/if-pre-up.d
  61. $(INSTALL_BIN) ./files/ppp.pre-up \
  62. ${IDIR_PPP}/etc/network/if-pre-up.d/05-ppp
  63. mod-radius-install:
  64. ${INSTALL_DIR} ${IDIR_PPP_MOD_RADIUS}/etc/radiusclient
  65. ${CP} ${WRKBUILD}/pppd/plugins/radius/etc/* \
  66. ${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. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPOE}/etc/ppp/templates
  76. ${INSTALL_DATA} ./files/etc/ppp/templates/pppoe \
  77. ${IDIR_PPP_MOD_PPPOE}/etc/ppp/templates/
  78. mod-pppoa-install:
  79. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPOA}/usr/lib/pppd/$(PKG_VERSION)
  80. ${INSTALL_BIN} $(WRKINST)/usr/lib/pppd/$(PKG_VERSION)/pppoatm.so \
  81. ${IDIR_PPP_MOD_PPPOA}/usr/lib/pppd/$(PKG_VERSION)
  82. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPOA}/etc/ppp/templates
  83. ${INSTALL_DATA} ./files/etc/ppp/templates/pppoa \
  84. ${IDIR_PPP_MOD_PPPOA}/etc/ppp/templates/
  85. mod-chat-install:
  86. ${INSTALL_DIR} ${IDIR_PPP_MOD_CHAT}/usr/sbin
  87. ${CP} ${WRKINST}/usr/sbin/chat ${IDIR_PPP_MOD_CHAT}/usr/sbin/
  88. mod-pppdump-install:
  89. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPDUMP}/usr/sbin
  90. ${CP} ${WRKINST}/usr/sbin/pppdump ${IDIR_PPP_MOD_PPPDUMP}/usr/sbin/
  91. mod-pppstats-install:
  92. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPSTATS}/usr/sbin
  93. ${CP} ${WRKINST}/usr/sbin/pppstats ${IDIR_PPP_MOD_PPPSTATS}/usr/sbin/
  94. mod-pppumts-install:
  95. ${INSTALL_DIR} ${IDIR_PPP_MOD_PPPUMTS}/etc/ppp/templates
  96. ${INSTALL_DATA} ./files/etc/ppp/templates/umts \
  97. ${IDIR_PPP_MOD_PPPUMTS}/etc/ppp/templates/
  98. $(INSTALL_DIR) ${IDIR_PPP_MOD_PPPUMTS}/etc/network/if-pre-up.d
  99. $(INSTALL_DIR) ${IDIR_PPP_MOD_PPPUMTS}/etc/network/if-post-down.d
  100. $(INSTALL_BIN) ./files/hso.if-up \
  101. ${IDIR_PPP_MOD_PPPUMTS}/etc/network/if-pre-up.d/06-hso
  102. $(INSTALL_BIN) ./files/hso.if-down \
  103. ${IDIR_PPP_MOD_PPPUMTS}/etc/network/if-post-down.d/06-hso
  104. include ${TOPDIR}/mk/pkg-bottom.mk