freebsd-ports/devel/qca/Makefile
Raphael Kubo da Costa f191df747e MFH: r417968 r418048 r420303
devel/qca: Fix building without SSLv3 and SHA-0

  - Add 2 patches from upstream project
    - Fix building when libssl does not have SSLv3
    - Fix building when libcrypto does not have SHA-0
  - Replace USE_OPENSSL with USES= ssl
  - Rework files/patch-libressl with `make makepatch`

Tested with devel/qca and devel/qca-qt5

PR:		210053
Approved by:	Maintainer time-out
Obtained from:	KDE
Differential Revision:	D6885

devel/qca: Fix build failure on 9.3 / OpenSSL 0.9.7

  - Re-add patch for compression to satisfy 0.9.7

PR:		210053

Adjust the SHA0 removal patch.

The upstream fix was still returning "sha0" in all_hash_types() even when SHA0
support is not present. The fix has also been submitted upstream.

PR:		211833
Submitted by:	matthew@reztek.cz

Approved by:	ports-secteam (junovitch)
2016-08-22 10:27:00 +00:00

51 lines
1.4 KiB
Makefile

# Created by: Vsevolod Stakhov <vsevolod@highsecure.ru>
# $FreeBSD$
PORTNAME= qca
PORTVERSION= 2.1.1
PORTREVISION= 1
CATEGORIES= devel
MASTER_SITES= KDE/stable/qca/${PORTVERSION}/src
MAINTAINER= kde@FreeBSD.org
COMMENT= Cross-platform crypto API for Qt 4
BUILD_DEPENDS= ${LOCALBASE}/share/certs/ca-root-nss.crt:security/ca_root_nss
RUN_DEPENDS= ${LOCALBASE}/share/certs/ca-root-nss.crt:security/ca_root_nss
USES= cmake:outsource tar:xz
CMAKE_ARGS= -DBUILD_PLUGINS=none -DBUILD_TESTS=no \
-DPKGCONFIG_INSTALL_PREFIX=${PREFIX}/libdata/pkgconfig \
-DQCA_FEATURE_INSTALL_DIR=${QT_MKSPECDIR}/features \
-DQCA_MAN_INSTALL_DIR=${PREFIX}/man
CONFIGURE_ENV= QC_CERTSTORE_PATH=${LOCALBASE}/share/certs/ca-root-nss.crt
USE_LDCONFIG= yes
.if defined(PKGNAMESUFFIX)
CMAKE_ARGS+= -DQCA_SUFFIX=qt5
USE_QT5= core buildtools_build qmake_build
.else
USE_QT4= corelib moc_build qmake_build rcc_build
CMAKE_ARGS+= -DQT4_BUILD=yes
.endif
PLIST_SUB= SHLIB_VER=${PORTVERSION}
OPTIONS_DEFINE= GNUPG OPENSSL SASL
OPTIONS_DEFAULT=GNUPG OPENSSL
OPTIONS_SUB= yes
GNUPG_CMAKE_ON= -DWITH_gnupg_PLUGIN=yes
GNUPG_RUN_DEPENDS= gpg2:security/gnupg
OPENSSL_CMAKE_ON= -DWITH_ossl_PLUGIN=yes
OPENSSL_USES= ssl
SASL_CMAKE_ON= -DWITH_cyrus-sasl_PLUGIN=yes
SASL_LIB_DEPENDS= libsasl2.so:security/cyrus-sasl2
post-patch:
# Qt Network module is used for tests only
${REINPLACE_CMD} 's,Core Network,Core,' ${WRKSRC}/CMakeLists.txt
.include <bsd.port.mk>