aboutsummaryrefslogtreecommitdiffstats
path: root/main/fcgi
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2009-07-24 08:01:31 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2009-07-24 08:01:31 +0000
commitb70981b68efcce5256eb11c6cd26ae123b10b6ea (patch)
treea38be6efae5e2ba15c2e839504632f9b7bfd5f91 /main/fcgi
parent2b4df81538b8398442d5296650905c70341dd8d3 (diff)
downloadaports-b70981b68efcce5256eb11c6cd26ae123b10b6ea.tar.bz2
aports-b70981b68efcce5256eb11c6cd26ae123b10b6ea.tar.xz
moved extra/* to main/
and fixed misc build issues
Diffstat (limited to 'main/fcgi')
-rw-r--r--main/fcgi/10-fcgi-2.4.0-Makefile.patch24
-rw-r--r--main/fcgi/20-fcgi-2.4.0-clientdata-pointer.patch96
-rw-r--r--main/fcgi/30-fcgi-2.4.0-html-updates.patch65
-rw-r--r--main/fcgi/APKBUILD42
4 files changed, 227 insertions, 0 deletions
diff --git a/main/fcgi/10-fcgi-2.4.0-Makefile.patch b/main/fcgi/10-fcgi-2.4.0-Makefile.patch
new file mode 100644
index 0000000000..dad4cd6e02
--- /dev/null
+++ b/main/fcgi/10-fcgi-2.4.0-Makefile.patch
@@ -0,0 +1,24 @@
+Index: fcgi-2.4.0/cgi-fcgi/Makefile.am
+===================================================================
+--- fcgi-2.4.0.orig/cgi-fcgi/Makefile.am
++++ fcgi-2.4.0/cgi-fcgi/Makefile.am
+@@ -11,5 +11,5 @@ INCLUDE_FILES = $(INCLUDEDIR)/fastcgi.
+ LIBDIR = ../libfcgi
+ LIBFCGI = $(LIBDIR)/libfcgi.la
+
+-LDADD = $(LIBFCGI)
++LDADD = $(LIBFCGI) -lm
+ cgi_fcgi_SOURCES = $(INCLUDE_FILES) cgi-fcgi.c
+Index: fcgi-2.4.0/examples/Makefile.am
+===================================================================
+--- fcgi-2.4.0.orig/examples/Makefile.am
++++ fcgi-2.4.0/examples/Makefile.am
+@@ -21,7 +21,7 @@ INCLUDE_FILES = $(INCLUDEDIR)/fastcgi.
+ LIBDIR = ../libfcgi
+ LIBFCGI = $(LIBDIR)/libfcgi.la
+
+-LDADD = $(LIBFCGI)
++LDADD = $(LIBFCGI) -lm
+
+ echo_SOURCES = $(INCLUDE_FILES) echo.c
+ echo_x_SOURCES = $(INCLUDE_FILES) echo-x.c
diff --git a/main/fcgi/20-fcgi-2.4.0-clientdata-pointer.patch b/main/fcgi/20-fcgi-2.4.0-clientdata-pointer.patch
new file mode 100644
index 0000000000..ba4793765d
--- /dev/null
+++ b/main/fcgi/20-fcgi-2.4.0-clientdata-pointer.patch
@@ -0,0 +1,96 @@
+Index: fcgi-2.4.0/cgi-fcgi/cgi-fcgi.c
+===================================================================
+--- fcgi-2.4.0.orig/cgi-fcgi/cgi-fcgi.c
++++ fcgi-2.4.0/cgi-fcgi/cgi-fcgi.c
+@@ -21,6 +21,7 @@ static const char rcsid[] = "$Id: cgi-fc
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
++#include <sys/types.h>
+
+ #include "fcgi_config.h"
+
+@@ -145,7 +146,7 @@ static FCGI_BeginRequestBody MakeBeginRe
+
+
+ static int bytesToRead; /* number of bytes to read from Web Server */
+-static int appServerSock = -1; /* Socket connected to FastCGI application,
++static size_t appServerSock = -1; /* Socket connected to FastCGI application,
+ * used by AppServerReadHandler and
+ * AppServerWriteHandler. */
+ static Buffer fromAS; /* Bytes read from the FCGI application server. */
+@@ -640,7 +641,7 @@ static int ParseArgs(int argc, char *arg
+ }
+ if((av[ac] = (char *)malloc(strlen(tp1)+1)) == NULL) {
+ fprintf(stderr, "Cannot allocate %d bytes\n",
+- strlen(tp1)+1);
++ (int)strlen(tp1)+1);
+ exit(-1);
+ }
+ strcpy(av[ac++], tp1);
+Index: fcgi-2.4.0/examples/threaded.c
+===================================================================
+--- fcgi-2.4.0.orig/examples/threaded.c
++++ fcgi-2.4.0/examples/threaded.c
+@@ -24,7 +24,7 @@ static int counts[THREAD_COUNT];
+
+ static void *doit(void *a)
+ {
+- int rc, i, thread_id = (int)a;
++ size_t rc, i, thread_id = (size_t)a;
+ pid_t pid = getpid();
+ FCGX_Request request;
+ char *server_name;
+@@ -53,7 +53,7 @@ static void *doit(void *a)
+ "<h1>FastCGI Hello! (multi-threaded C, fcgiapp library)</h1>"
+ "Thread %d, Process %ld<p>"
+ "Request counts for %d threads running on host <i>%s</i><p><code>",
+- thread_id, pid, THREAD_COUNT, server_name ? server_name : "?");
++ (int)thread_id, pid, THREAD_COUNT, server_name ? server_name : "?");
+
+ sleep(2);
+
+@@ -71,7 +71,7 @@ static void *doit(void *a)
+
+ int main(void)
+ {
+- int i;
++ size_t i;
+ pthread_t id[THREAD_COUNT];
+
+ FCGX_Init();
+Index: fcgi-2.4.0/include/fcgios.h
+===================================================================
+--- fcgi-2.4.0.orig/include/fcgios.h
++++ fcgi-2.4.0/include/fcgios.h
+@@ -93,7 +93,7 @@ extern "C" {
+ # if defined(__STDC__) || defined(__cplusplus)
+ typedef void *ClientData;
+ # else
+- typedef int *ClientData;
++ typedef size_t *ClientData;
+ # endif /* __STDC__ */
+ #define _CLIENTDATA
+ #endif
+Index: fcgi-2.4.0/libfcgi/os_unix.c
+===================================================================
+--- fcgi-2.4.0.orig/libfcgi/os_unix.c
++++ fcgi-2.4.0/libfcgi/os_unix.c
+@@ -1155,7 +1155,7 @@ int OS_Accept(int listen_sock, int fail_
+
+ for (;;) {
+ do {
+-#ifdef HAVE_SOCKLEN
++#ifdef HAVE_SYS_SOCKET_H
+ socklen_t len = sizeof(sa);
+ #else
+ int len = sizeof(sa);
+@@ -1255,7 +1255,7 @@ int OS_IsFcgi(int sock)
+ struct sockaddr_in in;
+ struct sockaddr_un un;
+ } sa;
+-#ifdef HAVE_SOCKLEN
++#ifdef HAVE_SYS_SOCKET_H
+ socklen_t len = sizeof(sa);
+ #else
+ int len = sizeof(sa);
diff --git a/main/fcgi/30-fcgi-2.4.0-html-updates.patch b/main/fcgi/30-fcgi-2.4.0-html-updates.patch
new file mode 100644
index 0000000000..ca10a6a603
--- /dev/null
+++ b/main/fcgi/30-fcgi-2.4.0-html-updates.patch
@@ -0,0 +1,65 @@
+Index: fcgi-2.4.0/doc/fcgi-devel-kit.htm
+===================================================================
+--- fcgi-2.4.0.orig/doc/fcgi-devel-kit.htm
++++ fcgi-2.4.0/doc/fcgi-devel-kit.htm
+@@ -19,7 +19,7 @@
+ </HEAD>
+ <BODY>
+ <P CLASS="c1">
+- <IMG BORDER="0" SRC="../images/fcgi-hd.gif" ALT="[[FastCGI]]"><BR CLEAR="all">
++ <IMG BORDER="0" SRC="images/fcgi-hd.gif" ALT="[[FastCGI]]"><BR CLEAR="all">
+ </P>
+ <H3 CLASS="c2">
+ FastCGI Developer&#39;s Kit
+Index: fcgi-2.4.0/doc/fcgi-java.htm
+===================================================================
+--- fcgi-2.4.0.orig/doc/fcgi-java.htm
++++ fcgi-2.4.0/doc/fcgi-java.htm
+@@ -20,7 +20,7 @@
+ </HEAD>
+ <BODY>
+ <DIV CLASS="c1">
+- <A HREF="http://fastcgi.com"><IMG BORDER="0" SRC="../images/fcgi-hd.gif" ALT="[[FastCGI]]"></A>
++ <A HREF="http://fastcgi.com"><IMG BORDER="0" SRC="images/fcgi-hd.gif" ALT="[[FastCGI]]"></A>
+ </DIV>
+ <BR CLEAR="all">
+ <DIV CLASS="c1">
+Index: fcgi-2.4.0/doc/fcgi-perf.htm
+===================================================================
+--- fcgi-2.4.0.orig/doc/fcgi-perf.htm
++++ fcgi-2.4.0/doc/fcgi-perf.htm
+@@ -19,7 +19,7 @@
+ </HEAD>
+ <BODY>
+ <DIV CLASS="c1">
+- <A HREF="http://fastcgi.com"><IMG BORDER="0" SRC="../images/fcgi-hd.gif" ALT="[[FastCGI]]"></A>
++ <A HREF="http://fastcgi.com"><IMG BORDER="0" SRC="images/fcgi-hd.gif" ALT="[[FastCGI]]"></A>
+ </DIV>
+ <BR CLEAR="all">
+ <DIV CLASS="c1">
+Index: fcgi-2.4.0/doc/fcgi-perl.htm
+===================================================================
+--- fcgi-2.4.0.orig/doc/fcgi-perl.htm
++++ fcgi-2.4.0/doc/fcgi-perl.htm
+@@ -19,7 +19,7 @@
+ </HEAD>
+ <BODY>
+ <DIV CLASS="c1">
+- <A HREF="http://fastcgi.com"><IMG BORDER="0" SRC="../images/fcgi-hd.gif" ALT="[[FastCGI]]"></A>
++ <A HREF="http://fastcgi.com"><IMG BORDER="0" SRC="images/fcgi-hd.gif" ALT="[[FastCGI]]"></A>
+ </DIV>
+ <BR CLEAR="all">
+
+Index: fcgi-2.4.0/doc/fcgi-tcl.htm
+===================================================================
+--- fcgi-2.4.0.orig/doc/fcgi-tcl.htm
++++ fcgi-2.4.0/doc/fcgi-tcl.htm
+@@ -19,7 +19,7 @@
+ </HEAD>
+ <BODY>
+ <DIV CLASS="c1">
+- <A HREF="http://fastcgi.com"><IMG BORDER="0" SRC="../images/fcgi-hd.gif" ALT="[[FastCGI]]"></A>
++ <A HREF="http://fastcgi.com"><IMG BORDER="0" SRC="images/fcgi-hd.gif" ALT="[[FastCGI]]"></A>
+ </DIV>
+ <BR CLEAR="all">
+ <DIV CLASS="c1">
diff --git a/main/fcgi/APKBUILD b/main/fcgi/APKBUILD
new file mode 100644
index 0000000000..fc208006cb
--- /dev/null
+++ b/main/fcgi/APKBUILD
@@ -0,0 +1,42 @@
+# Contributor: Carlo Landmeter <clandmeter@gmail.com>
+# Maintainer: Carlo Landmeter <clandmeter@gmail.com>
+pkgname=fcgi
+pkgver=2.4.0
+pkgrel=0
+pkgdesc="FAST CGI(fcgi) is a language independent, high performant extension to CGI"
+url="http://www.fastcgi.com"
+license="GPL"
+depends="uclibc"
+makedepends=""
+subpackages="$pkgname-dev"
+source="http://www.fastcgi.com/dist/${pkgname}-${pkgver}.tar.gz
+20-fcgi-2.4.0-clientdata-pointer.patch
+30-fcgi-2.4.0-html-updates.patch"
+
+build() {
+ cd "$srcdir/$pkgname-$pkgver"
+
+ for i in ../*.patch; do
+ msg "Applying $i"
+ patch -p1 < $i || return 1
+ done
+
+ export LIBS="$LIBS -lm"
+
+ # seems like there is no way to disable c++ from configure script
+ # the row below helps us to build even if g++ is installed on system
+ export CXX=false
+
+ ./configure --prefix=/usr \
+ --sysconfdir=/etc \
+ --mandir=/usr/share/man \
+ --infodir=/usr/share/info \
+ --enable-shared
+ make || return 1
+ make DESTDIR="$pkgdir" install
+
+}
+
+md5sums="d15060a813b91383a9f3c66faf84867e fcgi-2.4.0.tar.gz
+d2654525f06451c99b8cdd4cc00a963b 20-fcgi-2.4.0-clientdata-pointer.patch
+f26b536786f70b30a2d91c83d56e944c 30-fcgi-2.4.0-html-updates.patch"