From: "Anthony G. Basile" <blueness@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] dev/blueness:master commit in: dev-libs/axTLS/files/, dev-libs/axTLS/
Date: Fri, 6 Apr 2012 03:05:05 +0000 (UTC) [thread overview]
Message-ID: <1333681497.b36f1bfa7adbb3bf648029587b4fab2cfed51dc8.blueness@gentoo> (raw)
commit: b36f1bfa7adbb3bf648029587b4fab2cfed51dc8
Author: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
AuthorDate: Fri Apr 6 03:04:57 2012 +0000
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
CommitDate: Fri Apr 6 03:04:57 2012 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=dev/blueness.git;a=commit;h=b36f1bfa
dev-libs/axTLS: add static and cgi lua/php options
---
dev-libs/axTLS/Manifest | 6 +-
dev-libs/axTLS/axTLS-1.4.5.ebuild | 75 ++++++++++++++++++++++++++++++++++--
dev-libs/axTLS/files/config | 22 +++++-----
dev-libs/axTLS/metadata.xml | 3 +
4 files changed, 87 insertions(+), 19 deletions(-)
diff --git a/dev-libs/axTLS/Manifest b/dev-libs/axTLS/Manifest
index 7b0e41e..8349ad4 100644
--- a/dev-libs/axTLS/Manifest
+++ b/dev-libs/axTLS/Manifest
@@ -1,4 +1,4 @@
-AUX config 3082 RMD160 9cfff762eaa48cbf0df11f35e73ba56e06e383f7 SHA1 275c80296b114207cbdd1be3381206ab710d2f0c SHA256 04580d9e440a4034d5a58b0c027d30d15a075f3eb271f989f03182ffa271f839
+AUX config 3079 RMD160 17a8bb8279a62460b68a88a2c176b5de5b25a87d SHA1 50f5807e8fba78423dcd152ec12c64d991f9dc4d SHA256 c4f4537c3e61eaae9bc3b17805b0c5c18a777f2992f75a7a1ffc098d1085b289
DIST axTLS-1.4.5.tar.gz 1299325 RMD160 fb8f78578a998ed0a88cfef18127e4d24ff35bfc SHA1 33b8c4b7babd433d78889218bc5fa6932bfd0a24 SHA256 04e9c235d59cff98c393c920d4d7975b7ba32979c1d9675cee73996d22d232f1
-EBUILD axTLS-1.4.5.ebuild 672 RMD160 7c7a341a9759876335e316f241c780b02c313cba SHA1 92ee6f2f87664ebc5c693e6bac0e73f194f56ea4 SHA256 a0e6654f81490ae7494808e1a7ae5f81d8fa70c38c64a4e97024cdcd3373d36b
-MISC metadata.xml 328 RMD160 abed8943288a3272e4cc398976c6b4d63bcf47f1 SHA1 3c3e2a6be9bfe57f9f88f1ba3e986644e3a23654 SHA256 f699368493777fa91a5c1b5291dac1e5640b5ac99c2d0c5a6a2bf9d990ac9518
+EBUILD axTLS-1.4.5.ebuild 1993 RMD160 c7758f2af414ca08979cd9530a680b8d4c55f8d0 SHA1 c30cc1f43f26d017587f33fb673e2e2a91311e42 SHA256 2c696b605f274b8ef05f4c4ce060fe007e334a554d8f1bf067dd5f1d7ea05ba2
+MISC metadata.xml 539 RMD160 66d2200563130d8af1e6b9ea42aac0098cca0ece SHA1 977793dc0d626b3c9144cdac6e85ec137efd3e72 SHA256 678ce846bdfbf9df350ed0ba25520abe1588a12c229cbc54642269cf2fbe0966
diff --git a/dev-libs/axTLS/axTLS-1.4.5.ebuild b/dev-libs/axTLS/axTLS-1.4.5.ebuild
index 79e1f42..25c17da 100644
--- a/dev-libs/axTLS/axTLS-1.4.5.ebuild
+++ b/dev-libs/axTLS/axTLS-1.4.5.ebuild
@@ -4,6 +4,8 @@
EAPI="4"
+inherit user toolchain-funcs
+
DESCRIPTION="Embedded client/server TLSv1 SSL library and small HTTP(S) server"
HOMEPAGE="http://axtls.sourceforge.net/"
SRC_URI="mirror://sourceforge/axtls/${PN}-1.4.5.tar.gz"
@@ -11,21 +13,84 @@ SRC_URI="mirror://sourceforge/axtls/${PN}-1.4.5.tar.gz"
LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64 ~x86"
-IUSE="httpd"
+IUSE="httpd cgi-lua cgi-php static"
DEPEND=""
RDEPEND="${DEPEND}
- httpd? ( dev-lang/php )"
+ httpd? (
+ cgi-lua? ( dev-lang/lua )
+ cgi-php? ( dev-lang/php[cgi] )
+ )"
+
+REQUIRED_USE="
+ static? ( httpd )
+ cgi-lua? ( httpd )
+ cgi-php? ( httpd )"
S="${WORKDIR}/${PN}"
+AXTLS_GROUP="axtls"
+AXTLS_USER="axtls"
+
+pkg_setup() {
+ use httpd && {
+ ebegin "Creating axtls user and group"
+ enewgroup ${AXTLS_GROUP}
+ enewuser ${AXTLS_USER} -1 -1 -1 ${AXTLS_GROUP}
+ }
+}
+
+src_prepare() {
+ tc-export CC
+ sed -i -e "s:^HOSTCC.*:HOSTCC=${CC}:" \
+ "${S}"/config/Rules.mak
+}
+
src_configure() {
+ tc-export CC
+
cp "${FILESDIR}"/config "${S}"/config/.config
- ! use httpd && 's/^CONFIG_AXHTTPD/#CONFIG_AXHTTPD/'
- emake oldconfig
+
+ sed -i -e "s:^CONFIG_EXTRA_CFLAGS_OPTIONS.*$:CONFIG_EXTRA_CFLAGS_OPTIONS=\"${CFLAGS}\":" \
+ "${S}"/config/.config
+
+ sed -i -e "s:^CONFIG_EXTRA_LDFLAGS_OPTIONS.*$:CONFIG_EXTRA_LDFLAGS_OPTIONS=\"${LDLAGS}\":" \
+ "${S}"/config/.config
+
+ if use httpd; then
+
+ if ! use static; then
+ sed -i -e 's:^CONFIG_HTTP_STATIC_BUILD:# CONFIG_HTTP_STATIC_BUILD:' \
+ "${S}"/config/.config
+ fi
+
+ if ! use cgi-php && ! use cgi-lua; then
+ sed -i -e 's:^CONFIG_HTTP_HAS_CGI:# CONFIG_HTTP_HAS_CGI:' \
+ "${S}"/config/.config
+ fi
+
+ if ! use cgi-php; then
+ sed -i -e 's:,.php::' "${S}"/config/.config
+ fi
+
+ if ! use cgi-lua; then
+ sed -i -e 's:\.lua,::' \
+ -e 's:lua:php:' \
+ -e 's:^CONFIG_HTTP_ENABLE_LUA:# CONFIG_HTTP_ENABLE_LUA:' \
+ "${S}"/config/.config
+ fi
+
+ else
+
+ sed -i -e 's:^CONFIG_AXHTTPD:# CONFIG_AXHTTPD:' \
+ "${S}"/config/.config
+
+ fi
+
+ yes "n" | emake -j1 oldconfig
}
src_install() {
emake PREFIX="${ED}/usr" install
- mv "${ED}"/usr/bin/{,ax_}htpasswd
+ use httpd && mv "${ED}"/usr/bin/{,ax}htpasswd
}
diff --git a/dev-libs/axTLS/files/config b/dev-libs/axTLS/files/config
index 826c461..afed5f6 100644
--- a/dev-libs/axTLS/files/config
+++ b/dev-libs/axTLS/files/config
@@ -58,9 +58,9 @@ CONFIG_AXHTTPD=y
#
# Axhttpd Configuration
#
-# CONFIG_HTTP_STATIC_BUILD is not set
-CONFIG_HTTP_PORT=80
-CONFIG_HTTP_HTTPS_PORT=443
+CONFIG_HTTP_STATIC_BUILD=y
+CONFIG_HTTP_PORT=8080
+CONFIG_HTTP_HTTPS_PORT=4343
CONFIG_HTTP_SESSION_CACHE_SIZE=5
CONFIG_HTTP_WEBROOT="/var/www/localhost"
CONFIG_HTTP_TIMEOUT=300
@@ -69,16 +69,16 @@ CONFIG_HTTP_TIMEOUT=300
# CGI
#
CONFIG_HTTP_HAS_CGI=y
-CONFIG_HTTP_CGI_EXTENSIONS=".lua,.lp,.php"
-# CONFIG_HTTP_ENABLE_LUA is not set
-CONFIG_HTTP_LUA_PREFIX=""
+CONFIG_HTTP_CGI_EXTENSIONS=".lua,.php"
+CONFIG_HTTP_ENABLE_LUA=y
+CONFIG_HTTP_LUA_PREFIX="/usr"
# CONFIG_HTTP_BUILD_LUA is not set
-CONFIG_HTTP_CGI_LAUNCHER="/usr/bin/php"
+CONFIG_HTTP_CGI_LAUNCHER="/usr/bin/lua"
CONFIG_HTTP_DIRECTORIES=y
CONFIG_HTTP_HAS_AUTHORIZATION=y
# CONFIG_HTTP_HAS_IPV6 is not set
-# CONFIG_HTTP_ENABLE_DIFFERENT_USER is not set
-CONFIG_HTTP_USER=""
+CONFIG_HTTP_ENABLE_DIFFERENT_USER=y
+CONFIG_HTTP_USER="axtls"
CONFIG_HTTP_VERBOSE=y
CONFIG_HTTP_IS_DAEMON=y
@@ -100,8 +100,8 @@ CONFIG_LUA_CORE=""
#
# Samples
#
-CONFIG_SAMPLES=y
-CONFIG_C_SAMPLES=y
+# CONFIG_SAMPLES is not set
+# CONFIG_C_SAMPLES is not set
# CONFIG_CSHARP_SAMPLES is not set
# CONFIG_VBNET_SAMPLES is not set
# CONFIG_JAVA_SAMPLES is not set
diff --git a/dev-libs/axTLS/metadata.xml b/dev-libs/axTLS/metadata.xml
index 02ff70b..dd75ddb 100644
--- a/dev-libs/axTLS/metadata.xml
+++ b/dev-libs/axTLS/metadata.xml
@@ -7,5 +7,8 @@
</maintainer>
<use>
<flag name="httpd">Enables axhttpd web server component</flag>
+ <flag name="static">Statically build axhttpd server</flag>
+ <flag name="cgi-lua">Enables lua backed cgi for axhttpd server</flag>
+ <flag name="cgi-php">Enables php backed cgi for axhttpd server</flag>
</use>
</pkgmetadata>
next reply other threads:[~2012-04-06 3:05 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-04-06 3:05 Anthony G. Basile [this message]
-- strict thread matches above, loose matches on Subject: below --
2012-04-06 3:10 [gentoo-commits] dev/blueness:master commit in: dev-libs/axTLS/files/, dev-libs/axTLS/ Anthony G. Basile
2012-04-06 15:11 Anthony G. Basile
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1333681497.b36f1bfa7adbb3bf648029587b4fab2cfed51dc8.blueness@gentoo \
--to=blueness@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox