aboutsummaryrefslogtreecommitdiff
path: root/security/qca-tls
diff options
context:
space:
mode:
authorDmitry Sivachenko <demon@FreeBSD.org>2005-09-06 06:06:15 +0000
committerDmitry Sivachenko <demon@FreeBSD.org>2005-09-06 06:06:15 +0000
commit0a7ff81632bdd6c172352602d221a86d10be02a3 (patch)
tree1c859e9748f674debdac25455bc265a85c8c24d3 /security/qca-tls
parent054a9788549501c7e4e53d991e1a5e471e3946c1 (diff)
downloadports-0a7ff81632bdd6c172352602d221a86d10be02a3.tar.gz
ports-0a7ff81632bdd6c172352602d221a86d10be02a3.zip
Notes
Diffstat (limited to 'security/qca-tls')
-rw-r--r--security/qca-tls/Makefile4
-rw-r--r--security/qca-tls/files/patch-configure33
-rw-r--r--security/qca-tls/files/patch-qca-tls.cpp26
3 files changed, 51 insertions, 12 deletions
diff --git a/security/qca-tls/Makefile b/security/qca-tls/Makefile
index c4ba2dff94ec..1866ad868c8e 100644
--- a/security/qca-tls/Makefile
+++ b/security/qca-tls/Makefile
@@ -19,10 +19,12 @@ BUILD_DEPENDS= qmake:${PORTSDIR}/devel/qmake
HAS_CONFIGURE= yes
USE_X_PREFIX= yes
USE_BZIP2= yes
+USE_OPENSSL= yes
USE_QT_VER= 3
QT_NONSTANDARD= yes
CONFIGURE_ENV= QMAKESPEC=${LOCALBASE}/share/qt/mkspecs/freebsd-g++
-CONFIGURE_ARGS= --qtdir=${X11BASE}
+CONFIGURE_ARGS= --qtdir=${X11BASE} \
+ --with-openssl-inc=${OPENSSLINC} --with-openssl-lib=${OPENSSLLIB}
MAKE_ARGS+= QTDIR=${X11BASE} \
QMAKESPEC=${LOCALBASE}/share/qt/mkspecs/freebsd-g++
diff --git a/security/qca-tls/files/patch-configure b/security/qca-tls/files/patch-configure
index f7bc54689dcc..e1f3a26967cd 100644
--- a/security/qca-tls/files/patch-configure
+++ b/security/qca-tls/files/patch-configure
@@ -1,5 +1,5 @@
--- configure.orig Wed Dec 17 23:54:50 2003
-+++ configure Tue Nov 16 12:33:52 2004
++++ configure Fri Aug 26 11:59:28 2005
@@ -20,17 +20,17 @@
while [ $# -gt 0 ]; do
case "$1" in
@@ -21,15 +21,6 @@
shift
;;
-@@ -43,6 +43,8 @@
- esac
- done
-
-+QC_WITH_OPENSSL_INC=/usr/include
-+QC_WITH_OPENSSL_LIB=/usr/lib
-
- echo "Configuring qca-tls ..."
-
@@ -84,7 +86,7 @@
echo Warning: qmake not in \$QTDIR/bin/qmake
echo trying to find it in \$PATH
@@ -48,7 +39,27 @@
lib = s;
}
else {
-@@ -570,13 +570,6 @@
+@@ -175,6 +175,19 @@
+ if(ret == 0)
+ conf->addDefine("OSSL_097");
+
++ // is it at least openssl 0.9.8?
++ str =
++ "#include<openssl/opensslv.h>\n"
++ "int main()\n"
++ "{\n"
++ " unsigned long x = OPENSSL_VERSION_NUMBER;\n"
++ " if(x >= 0x00908000) return 0; else return 1;\n"
++ "}\n";
++ if(!conf->doCompileAndLink(str, ext, &ret))
++ return false;
++ if(ret == 0)
++ conf->addDefine("OSSL_098");
++
+ if(!inc.isEmpty())
+ conf->addIncludePath(inc);
+ if(kb)
+@@ -570,13 +583,6 @@
echo
exit 1;
fi
diff --git a/security/qca-tls/files/patch-qca-tls.cpp b/security/qca-tls/files/patch-qca-tls.cpp
new file mode 100644
index 000000000000..931c634383b0
--- /dev/null
+++ b/security/qca-tls/files/patch-qca-tls.cpp
@@ -0,0 +1,26 @@
+--- qca-tls.cpp.orig Fri Aug 26 10:47:35 2005
++++ qca-tls.cpp Fri Aug 26 10:51:07 2005
+@@ -454,7 +454,11 @@
+ if(!r) {
+ // try this other public function, for whatever reason
+ p = (void *)in;
++#ifdef OSSL_098
++ r = d2i_RSA_PUBKEY(NULL, (const unsigned char **)&p, len);
++#else
+ r = d2i_RSA_PUBKEY(NULL, (unsigned char **)&p, len);
++#endif
+ }
+ if(r) {
+ if(pub) {
+@@ -799,7 +803,11 @@
+ bool createFromDER(const char *in, unsigned int len)
+ {
+ unsigned char *p = (unsigned char *)in;
++#ifdef OSSL_098
++ X509 *t = d2i_X509(NULL, (const unsigned char**)&p, len);
++#else
+ X509 *t = d2i_X509(NULL, &p, len);
++#endif
+ if(!t)
+ return false;
+ fromX509(t);