1
0

Makefile 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152
  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:= squid
  5. PKG_VERSION:= 3.1.11
  6. PKG_RELEASE:= 1
  7. PKG_MD5SUM:= 08de963a4d0ba86c59d33af89fa46384
  8. PKG_DESCR:= squid web and cache proxy
  9. PKG_SECTION:= proxy
  10. PKG_DEPENDS:= libopenssl libpthread
  11. PKG_BUILDDEP:= openssl libtool
  12. PKG_URL:= http://www.squid-cache.org/
  13. PKG_SITES:= http://www.squid-cache.org/Versions/v3/3.1/
  14. PKG_MULTI:= 1
  15. PKG_NEED_CXX:= 1
  16. PKG_SUBPKGS:= SQUID SQUID_MOD_BASIC_AUTH_GETPWNAM SQUID_MOD_BASIC_AUTH_NCSA
  17. PKG_SUBPKGS+= SQUID_MOD_BASIC_AUTH_SMB SQUID_MOD_DIGEST_AUTH_PASSWORD
  18. PKG_SUBPKGS+= SQUID_MOD_EXTERNAL_ACL_IP_USER SQUID_MOD_EXTERNAL_ACL_UNIX_GROUP
  19. PKG_SUBPKGS+= SQUID_MOD_NTLM_AUTH_FAKEAUTH
  20. PKG_HOST_DEPENDS:= !netbsd !cygwin
  21. AUTH_MODULES:= basic digest ntlm
  22. ifneq (${ADK_PACKAGE_SQUID_MOD_BASIC_AUTH_GETPWNAM},)
  23. BASIC_AUTH_HELPERS+= getpwnam
  24. endif
  25. ifneq (${ADK_PACKAGE_SQUID_MOD_BASIC_AUTH_NCSA},)
  26. BASIC_AUTH_HELPERS+= NCSA
  27. endif
  28. ifneq (${ADK_PACKAGE_SQUID_MOD_BASIC_AUTH_SMB},)
  29. BASIC_AUTH_HELPERS+= SMB
  30. endif
  31. ifneq (${ADK_PACKAGE_SQUID_MOD_DIGEST_AUTH_PASSWORD},)
  32. DIGEST_AUTH_HELPERS:= password
  33. endif
  34. ifneq (${ADK_PACKAGE_SQUID_MOD_EXTERNAL_ACL_IP_USER},)
  35. EXTERNAL_ACL_HELPERS+= ip_user
  36. endif
  37. ifneq (${ADK_PACKAGE_SQUID_MOD_EXTERNAL_ACL_UNIX_GROUP},)
  38. EXTERNAL_ACL_HELPERS+= unix_group
  39. endif
  40. ifneq (${ADK_PACKAGE_SQUID_MOD_NTLM_AUTH_FAKEAUTH},)
  41. NTLM_AUTH_HELPERS+= fakeauth
  42. endif
  43. include ${TOPDIR}/mk/package.mk
  44. define PKG_mod_template
  45. INSTALL_MODS_$${ADK_PACKAGE_${1}}+= ${2}-install
  46. ${2}-install:
  47. ${INSTALL_DIR} $${IDIR_${1}}/usr/lib/squid
  48. ${INSTALL_BIN} ${WRKINST}/usr/lib/squid/${2} \
  49. $${IDIR_${1}}/usr/lib/squid/
  50. endef
  51. $(eval $(call PKG_template,SQUID,${PKG_NAME},${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  52. $(eval $(call PKG_template,SQUID_MOD_BASIC_AUTH_GETPWNAM,${PKG_NAME}-mod-basic-auth-getpwnam,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  53. $(eval $(call PKG_template,SQUID_MOD_BASIC_AUTH_NCSA,${PKG_NAME}-mod-basic-auth-ncsa,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  54. $(eval $(call PKG_template,SQUID_MOD_BASIC_AUTH_SMB,${PKG_NAME}-mod-basic-auth-smb,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  55. $(eval $(call PKG_template,SQUID_MOD_DIGEST_AUTH_PASSWORD,${PKG_NAME}-mod-digest-auth-password,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  56. $(eval $(call PKG_template,SQUID_MOD_EXTERNAL_ACL_IP_USER,${PKG_NAME}-mod-external-acl-ip-user,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  57. $(eval $(call PKG_template,SQUID_MOD_EXTERNAL_ACL_UNIX_GROUP,${PKG_NAME}-mod-external-acl-unix-group,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  58. $(eval $(call PKG_template,SQUID_MOD_NTLM_AUTH_FAKEAUTH,${PKG_NAME}-mod-ntlm-auth-fakeauth,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  59. $(eval $(call PKG_mod_template,SQUID_MOD_BASIC_AUTH_GETPWNAM,getpwname_auth))
  60. $(eval $(call PKG_mod_template,SQUID_MOD_BASIC_AUTH_LDAP,ldap))
  61. $(eval $(call PKG_mod_template,SQUID_MOD_BASIC_AUTH_NCSA,ncsa_auth))
  62. $(eval $(call PKG_mod_template,SQUID_MOD_BASIC_AUTH_SMB,smb_auth))
  63. $(eval $(call PKG_mod_template,SQUID_MOD_DIGEST_AUTH_PASSWORD,digest_pw_auth))
  64. $(eval $(call PKG_mod_template,SQUID_MOD_EXTERNAL_ACL_IP_USER,ip_user_check))
  65. $(eval $(call PKG_mod_template,SQUID_MOD_EXTERNAL_ACL_LDAP_GROUP,ldap_auth))
  66. $(eval $(call PKG_mod_template,SQUID_MOD_EXTERNAL_ACL_UNIX_GROUP,squid_unix_group))
  67. $(eval $(call PKG_mod_template,SQUID_MOD_NTLM_AUTH_FAKEAUTH,fakeauth_auth))
  68. CONFIGURE_ENV+= ac_cv_sizeof_void_p=4 \
  69. ac_cv_sizeof_short=2 \
  70. ac_cv_sizeof_int=4 \
  71. ac_cv_sizeof_long=4 \
  72. ac_cv_sizeof_long_long=8 \
  73. ac_cv_sizeof___int64=0 \
  74. ac_cv_sizeof_int16_t=2 \
  75. ac_cv_sizeof_uint16_t=2 \
  76. ac_cv_sizeof_u_int16_t=2 \
  77. ac_cv_sizeof_int32_t=4 \
  78. ac_cv_sizeof_uint32_t=4 \
  79. ac_cv_sizeof_u_int32_t=4 \
  80. ac_cv_sizeof_int64_t=8 \
  81. ac_cv_sizeof_uint64_t=8 \
  82. ac_cv_sizeof_u_int64_t=8 \
  83. ac_cv_func_setresuid=no \
  84. ac_cv_func_va_copy=no \
  85. ac_cv_func___va_copy=no \
  86. ac_cv_epoll_works=yes \
  87. ac_cv_lib_nsl_main=no \
  88. ac_cv_func_strnstr=no \
  89. squid_cv_pf_inet6=yes \
  90. ac_cv_have_squid=yes
  91. XAKE_FLAGS+= MKDIR_P="mkdir -p"
  92. CONFIGURE_ARGS+= --datadir=/usr/share/squid \
  93. --libexecdir=/usr/lib/squid \
  94. --sysconfdir=/etc/squid \
  95. --with-gnu-ld \
  96. --enable-x-accelerator-vary \
  97. --with-pthreads \
  98. --with-dl \
  99. --disable-debug-cbdata \
  100. --enable-kill-parent-hack \
  101. --enable-arp-acl \
  102. --enable-ssl \
  103. --enable-err-languages=English \
  104. --enable-default-err-language=English \
  105. --enable-linux-netfilter \
  106. --enable-icmp \
  107. --enable-underscores \
  108. --enable-cache-digests \
  109. --enable-referer-log \
  110. --enable-delay-pools \
  111. --without-libcap \
  112. --disable-snmp \
  113. --disable-esi \
  114. --disable-htcp \
  115. --disable-wccp \
  116. --disable-wccpv2 \
  117. --enable-useragent-log \
  118. --with-openssl=${STAGING_TARGET_DIR}/usr \
  119. --enable-negotiate-auth-helpers=no \
  120. --enable-auth="${AUTH_MODULES}" \
  121. --enable-basic-auth-helpers="${BASIC_AUTH_HELPERS}" \
  122. --enable-ntlm-auth-helpers="${NTLM_AUTH_HELPERS}" \
  123. --enable-digest-auth-helpers="${DIGEST_AUTH_HELPERS}" \
  124. --enable-external-acl-helpers="${EXTERNAL_ACL_HELPERS}"
  125. post-install: ${INSTALL_MODS_y} ${INSTALL_MODS_m}
  126. ${INSTALL_DIR} ${IDIR_SQUID}/etc/squid
  127. ${INSTALL_DATA} ${WRKINST}/etc/squid/mime.conf \
  128. ${IDIR_SQUID}/etc/squid/
  129. ${INSTALL_DATA} ./files/squid.conf ${IDIR_SQUID}/etc/squid/
  130. ${INSTALL_DIR} ${IDIR_SQUID}/usr/share/squid/errors
  131. ${CP} ${WRKINST}/usr/share/squid/errors/en \
  132. ${IDIR_SQUID}/usr/share/squid/errors
  133. ${CP} ${WRKINST}/usr/share/squid/icons ${IDIR_SQUID}/usr/share/squid/
  134. ${INSTALL_DIR} ${IDIR_SQUID}/usr/sbin ${IDIR_SQUID}/usr/lib/squid
  135. ${INSTALL_BIN} ${WRKINST}/usr/sbin/squid ${IDIR_SQUID}/usr/sbin/
  136. ${INSTALL_BIN} ${WRKINST}/usr/lib/squid/unlinkd \
  137. ${IDIR_SQUID}/usr/lib/squid
  138. include ${TOPDIR}/mk/pkg-bottom.mk