aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--www/mod_auth_mysql_another/Makefile52
-rw-r--r--www/mod_auth_mysql_another/distinfo4
-rw-r--r--www/mod_auth_mysql_another/files/patch-Makefile14
-rw-r--r--www/mod_auth_mysql_another/files/patch-mod_auth_mysql.c33
4 files changed, 19 insertions, 84 deletions
diff --git a/www/mod_auth_mysql_another/Makefile b/www/mod_auth_mysql_another/Makefile
index 91f5cfe4457e..2dd75bbfe55c 100644
--- a/www/mod_auth_mysql_another/Makefile
+++ b/www/mod_auth_mysql_another/Makefile
@@ -4,54 +4,36 @@
#
# $FreeBSD$
-PORTNAME= mod_auth_mysql_another
-PORTVERSION= 2.0
+PORTNAME= mod_auth_mysql
+PORTVERSION= 2.9.0
CATEGORIES= www
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
-MASTER_SITE_SUBDIR= modauthmysql
-DISTNAME= mod_auth_mysql
-EXTRACT_SUFX= .tgz
+MASTER_SITE_SUBDIR= ${PORTNAME:S/_//g}
+PKGNAMESUFFIX= _another
MAINTAINER= mbr@FreeBSD.org
COMMENT= Allows users to use MySQL databases for user authentication
-.include <bsd.port.pre.mk>
-
-.if exists(${LOCALBASE}/lib/mysql/libmysqlclient.so.10)
-LIB_DEPENDS= mysqlclient.10:${PORTSDIR}/databases/mysql323-client
-.else
-.if exists(${LOCALBASE}/lib/mysql/libmysqlclient.so.14)
-LIB_DEPENDS= mysqlclient.14:${PORTSDIR}/databases/mysql41-client
-.else
-LIB_DEPENDS= mysqlclient.12:${PORTSDIR}/databases/mysql40-client
-.endif
-.endif
-
-.if exists(${LOCALBASE}/include/apache2/apr.h)
-WITH_APACHE2= yes
-.endif
-
-.if defined(WITH_APACHE2)
-APACHE_VER= APACHE2
-PLIST_SUB= VER="2"
-DSO= mod_auth_mysql.la
-.else
-APACHE_VER= APACHE1
-PLIST_SUB= VER=""
-DSO= mod_auth_mysql.so
-.endif
+USE_MYSQL= YES
-BUILD_DEPENDS= ${APXS}:${PORTSDIR}/${APACHE_PORT}
-RUN_DEPENDS= ${APXS}:${PORTSDIR}/${APACHE_PORT}
+SHORTMODNAME= mysql_auth
+AP_FAST_BUILD= YES
+AP_GENPLIST= YES
+AP_INC= ${LOCALBASE}/include/mysql
+AP_LIB= ${LOCALBASE}/lib/mysql
+AP_EXTRAS= -DAPACHE${AP_VER} -lmysqlclient -lz -lm
-post-patch:
- @${SED} 's|%%LOCALBASE%%|${LOCALBASE}|g;s|%%APXS%%|${APXS}|g;s|%%APACHE_VER%%|${APACHE_VER}|g;s|%%DSO%%|${DSO}|g' \
- ${WRKDIR}/mod_auth_mysql/Makefile.orig > ${WRKDIR}/mod_auth_mysql/Makefile
+.include <bsd.port.pre.mk>
.if !defined(NOPORTDOCS)
+post-build:
+ @${ECHO} "%%PORTDOCS%%%%DOCSDIR%%/README" >> ${PLIST}
+ @${ECHO} "%%PORTDOCS%%@dirrm %%DOCSDIR%%" >> ${PLIST}
+
post-install:
@${MKDIR} ${DOCSDIR}
@${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}
.endif
+.include "${PORTSDIR}/www/apache2/Makefile.modules.3rd"
.include <bsd.port.post.mk>
diff --git a/www/mod_auth_mysql_another/distinfo b/www/mod_auth_mysql_another/distinfo
index a5f42993bc28..4c229f0e9304 100644
--- a/www/mod_auth_mysql_another/distinfo
+++ b/www/mod_auth_mysql_another/distinfo
@@ -1,2 +1,2 @@
-MD5 (mod_auth_mysql.tgz) = b6646a117703b3704091e8f19f02e43e
-SIZE (mod_auth_mysql.tgz) = 9953
+MD5 (mod_auth_mysql-2.9.0.tar.gz) = bc30f7a5a3182869cb48177732a18bd9
+SIZE (mod_auth_mysql-2.9.0.tar.gz) = 17499
diff --git a/www/mod_auth_mysql_another/files/patch-Makefile b/www/mod_auth_mysql_another/files/patch-Makefile
deleted file mode 100644
index 39ea5d440d2c..000000000000
--- a/www/mod_auth_mysql_another/files/patch-Makefile
+++ /dev/null
@@ -1,14 +0,0 @@
---- /dev/null Sat Apr 20 17:11:40 2002
-+++ Makefile.orig Sat Apr 20 17:12:22 2002
-@@ -0,0 +1,11 @@
-+APXS = %%APXS%%
-+DSO = %%DSO%%
-+SRCS = mod_auth_mysql.c
-+OPTS = -D %%APACHE_VER%% -I%%LOCALBASE%%/include -L%%LOCALBASE%%/lib/mysql -lmysqlclient
-+
-+all:
-+ $(APXS) -c $(OPTS) $(SRCS)
-+
-+install:
-+ $(APXS) -i -a $(DSO)
-+
diff --git a/www/mod_auth_mysql_another/files/patch-mod_auth_mysql.c b/www/mod_auth_mysql_another/files/patch-mod_auth_mysql.c
deleted file mode 100644
index d8a75fd7f455..000000000000
--- a/www/mod_auth_mysql_another/files/patch-mod_auth_mysql.c
+++ /dev/null
@@ -1,33 +0,0 @@
---- mod_auth_mysql.c Sat May 10 16:12:34 2003
-+++ mod_auth_mysql.c Sun Jan 11 13:16:47 2004
-@@ -97,6 +97,7 @@
- * MODULE-DEFINITION-END
- */
-
-+#define MYSQL_CRYPT_LEN 17U
-
- #ifdef APACHE2
- #define PCALLOC apr_pcalloc
-@@ -617,7 +618,8 @@
- conn_rec *c = r->connection;
- const char *sent_pw, *real_pw;
- int res;
-- char *scrambled_sent_pw;
-+ unsigned long hash_res[2];
-+ char scrambled_sent_pw[MYSQL_CRYPT_LEN];
-
- if ((res = ap_get_basic_auth_pw (r, &sent_pw)))
- return res;
-@@ -658,8 +660,10 @@
-
- /* if AuthMySQLScrambledPassword is On, compare the scrambled password */
- if(sec->mysqlScrambled) {
-- scrambled_sent_pw = PCALLOC(r->pool, 33);
-- make_scrambled_password(scrambled_sent_pw, sent_pw);
-+ /* make_scrambled_password(scrambled_sent_pw, sent_pw); */
-+ hash_password(hash_res, sent_pw);
-+ snprintf(scrambled_sent_pw, sizeof scrambled_sent_pw, "%08lx%08lx",
-+ hash_res[0], hash_res[1]);
- if(strcmp(real_pw, scrambled_sent_pw)) {
- passwords_match = 0;
- }