Skip to content

Instantly share code, notes, and snippets.

@jbergstroem
Last active August 29, 2015 13:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jbergstroem/9384885 to your computer and use it in GitHub Desktop.
Save jbergstroem/9384885 to your computer and use it in GitHub Desktop.
nginx-1.5.10.ebuild -> nginx-1.5.11.ebuild
--- nginx-1.5.10.ebuild 2014-02-10 14:12:24.000000000 +1100
+++ nginx-1.5.11.ebuild 2014-03-06 19:28:27.534442626 +1100
@@ -78,13 +78,13 @@
HTTP_METRICS_MODULE_WD="${WORKDIR}/ngx_metrics-${HTTP_METRICS_MODULE_PV}"
# naxsi-core (https://github.com/nbs-system/naxsi, GPLv2+)
-HTTP_NAXSI_MODULE_PV="0.53-1"
+HTTP_NAXSI_MODULE_PV="0.53-2"
HTTP_NAXSI_MODULE_P="ngx_http_naxsi-${HTTP_NAXSI_MODULE_PV}"
HTTP_NAXSI_MODULE_URI="https://github.com/nbs-system/naxsi/archive/${HTTP_NAXSI_MODULE_PV}.tar.gz"
HTTP_NAXSI_MODULE_WD="${WORKDIR}/naxsi-${HTTP_NAXSI_MODULE_PV}/naxsi_src"
# nginx-rtmp-module (http://github.com/arut/nginx-rtmp-module, BSD license)
-RTMP_MODULE_PV="1.1.2"
+RTMP_MODULE_PV="1.1.3"
RTMP_MODULE_P="ngx_rtmp-${RTMP_MODULE_PV}"
RTMP_MODULE_URI="http://github.com/arut/nginx-rtmp-module/archive/v${RTMP_MODULE_PV}.tar.gz"
RTMP_MODULE_WD="${WORKDIR}/nginx-rtmp-module-${RTMP_MODULE_PV}"
@@ -251,13 +251,18 @@
epatch "${FILESDIR}/${PN}-1.4.1-fix-perl-install-path.patch"
if use nginx_modules_http_upstream_check; then
- epatch "${FILESDIR}"/upstream-check-1.5.8.patch
+ epatch "${FILESDIR}"/upstream-check-${PV}.patch
fi
if use nginx_modules_http_security; then
- cd "${HTTP_SECURITY_MODULE_WD}/nginx/modsecurity"
- epatch "${FILESDIR}/modsecurity-${HTTP_SECURITY_MODULE_PV}-include-paths.patch"
- cd -
+ sed -i \
+ -e 's/apr-1.0/apr-1/' \
+ -e 's/-llua5.1/-llua/' \
+ "${HTTP_SECURITY_MODULE_WD}/nginx/modsecurity/config"
+ fi
+
+ if use nginx_modules_http_lua; then
+ sed -i -e 's/-llua5.1/-llua/' "${HTTP_LUA_MODULE_WD}/config"
fi
find auto/ -type f -print0 | xargs -0 sed -i 's:\&\& make:\&\& \\$(MAKE):' || die
@jbergstroem
Copy link
Author

Changes

  • bump naxsi and rtmp module
  • use Tiziano Muller's updated http_upstream_check patch
  • drop modsecurity patch
  • use simple sed's for include/lib path so mod security and lua properly builds

Open questions

  • modsecurity has a lot of stuff related to lua. do we care? (should build fine separate from the lua module but we don't control nor dep for dev-lang/lua which their autoconf script will pick up)
  • the lua module checks for lua over luajit. do we care?

@jbergstroem
Copy link
Author

Oh, forgot to mention. Tested with NGINX_MODULES_HTTP="*" emerge nginx

@jbergstroem
Copy link
Author

Actually, modsecurity is properly configured with lua. I really need to do my homework :/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment