Mail archive
alpine-aports

[alpine-aports] [PATCH] testing/libmilter: new aport Sendmail Mail Filter API http://www.sendmail.com/sm/open_source/milter

From: Valery Kartel <valery.kartel_at_gmail.com>
Date: Fri, 22 Jan 2016 15:12:14 +0200

---
 testing/libmilter/APKBUILD                  | 53 +++++++++++++++++++++++++++
 testing/libmilter/libmilter-sharedlib.patch | 55 +++++++++++++++++++++++++++++
 2 files changed, 108 insertions(+)
 create mode 100644 testing/libmilter/APKBUILD
 create mode 100644 testing/libmilter/libmilter-sharedlib.patch
diff --git a/testing/libmilter/APKBUILD b/testing/libmilter/APKBUILD
new file mode 100644
index 0000000..e580849
--- /dev/null
+++ b/testing/libmilter/APKBUILD
_at_@ -0,0 +1,53 @@
+# Maintainer: Valery Kartel <valery.kartel_at_gmail.com>
+# Contributor: Valery Kartel <valery.kartel_at_gmail.com>
+pkgname=libmilter
+_pkgname="sendmail"
+pkgver=1.0.2
+_pkgver=8.15.2
+pkgrel=0
+pkgdesc="Sendmail Mail Filter API"
+url="http://www.sendmail.com/sm/open_source"
+arch="all"
+license="custom"
+depends=""
+depends_dev=""
+makedepends="$depends_dev m4 linux-headers bsd-compat-headers"
+install=""
+subpackages="$pkgname-dev $pkgname-doc"
+source="ftp://ftp.sendmail.org/pub/$_pkgname/$_pkgname.$_pkgver.tar.gz
+	libmilter-sharedlib.patch"
+
+_builddir="$srcdir"/$_pkgname-$_pkgver
+
+prepare() {
+	cd "$_builddir"
+	for i in $source; do
+		case $i in
+		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
+		esac
+	done
+}
+
+build() {
+	cd "$_builddir"
+	make -j1 -C libmilter MILTER_SOVER=$pkgver || return 1
+}
+
+package() {
+	cd "$_builddir"
+	mkdir -p "$pkgdir"/usr/lib
+	make -j1 -C libmilter \
+		INCOWN=root INCGRP=root INCMODE=644 \
+		LIBOWN=root LIBGRP=root LIBMODE=644 UBINMODE=755 \
+		MILTER_SOVER=$pkgver DESTDIR="$pkgdir" install || return 1
+	install -Dm644 libmilter/README "$pkgdir"/usr/share/doc/$pkgname/README
+	cp -r libmilter/docs "$pkgdir"/usr/share/doc/$pkgname/
+	install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/license
+}
+
+md5sums="a824fa7dea4d3341efb6462ccd816f00  sendmail.8.15.2.tar.gz
+49558fc2c9e38f433e0dc64d76705c05  libmilter-sharedlib.patch"
+sha256sums="24f94b5fd76705f15897a78932a5f2439a32b1a2fdc35769bb1a5f5d9b4db439  sendmail.8.15.2.tar.gz
+3a753b0881fe622814b471ee5f9037905c7cc3ed08ef74908464ab5307e59d5a  libmilter-sharedlib.patch"
+sha512sums="04feb37316c13b66b1518596507a7da7c16cb0bf1abf10367f7fd888a428fadb093a9efa55342fa55b936c3f0cbdc63b9e2505cd99201a69a0c05b8ad65f49f9  sendmail.8.15.2.tar.gz
+31c36b57739946c1b9c7c85307fe5c53c45d7f8cbf427a0f2248db8b74871a6f5a30ef1af524915821aeca54310d28272bcd0a587cb918192214fa5c30e4a8da  libmilter-sharedlib.patch"
diff --git a/testing/libmilter/libmilter-sharedlib.patch b/testing/libmilter/libmilter-sharedlib.patch
new file mode 100644
index 0000000..43ec786
--- /dev/null
+++ b/testing/libmilter/libmilter-sharedlib.patch
_at_@ -0,0 +1,55 @@
+diff -Nru sendmail-8.14.3.orig/devtools/M4/UNIX/milterlibrary.m4 sendmail-8.14.3/devtools/M4/UNIX/milterlibrary.m4
+--- sendmail-8.14.3.orig/devtools/M4/UNIX/milterlibrary.m4	1970-01-01 01:00:00.000000000 +0100
++++ sendmail-8.14.3/devtools/M4/UNIX/milterlibrary.m4	2009-08-22 21:51:10.000000000 +0200
+_at_@ -0,0 +1,39 @@
++divert(-1)
++#
++# Copyright (c) 1999-2001 Sendmail, Inc. and its suppliers.
++#	All rights reserved.
++#
++# By using this file, you agree to the terms and conditions set
++# forth in the LICENSE file which can be found at the top level of
++# the sendmail distribution.
++#
++#
++#  Definitions for Makefile construction for sendmail
++#
++divert(0)dnl
++include(confBUILDTOOLSDIR`/M4/'bldM4_TYPE_DIR`/links.m4')dnl
++bldLIST_PUSH_ITEM(`bldC_PRODUCTS', bldCURRENT_PRODUCT)dnl
++bldPUSH_TARGET(bldCURRENT_PRODUCT`.so' bldCURRENT_PRODUCT`.a')dnl
++bldPUSH_INSTALL_TARGET(`install-'bldCURRENT_PRODUCT)dnl
++bldPUSH_CLEAN_TARGET(bldCURRENT_PRODUCT`-clean')dnl
++
++include(confBUILDTOOLSDIR`/M4/'bldM4_TYPE_DIR`/defines.m4')
++divert(bldTARGETS_SECTION)
++bldCURRENT_PRODUCT.so: ${BEFORE} ${bldCURRENT_PRODUCT`OBJS'}
++	${CCLINK} ${LDOPTS_SO} -o bldCURRENT_PRODUCT.so -Wl,confSONAME,bldCURRENT_PRODUCT.so.${MILTER_SOVER} ${bldCURRENT_PRODUCT`OBJS'} -lc ${LIBS}
++bldCURRENT_PRODUCT.a: ${BEFORE} ${bldCURRENT_PRODUCT`OBJS'}
++	${AR} ${AROPTS} bldCURRENT_PRODUCT.a ${bldCURRENT_PRODUCT`OBJS'}
++	${RANLIB} ${RANLIBOPTS} bldCURRENT_PRODUCT.a
++ifdef(`bldLINK_SOURCES', `bldMAKE_SOURCE_LINKS(bldLINK_SOURCES)')
++
++install-`'bldCURRENT_PRODUCT: bldCURRENT_PRODUCT.so bldCURRENT_PRODUCT.a
++ifdef(`bldINSTALLABLE', `	ifdef(`confMKDIR', `if [ ! -d "${DESTDIR}${bldINSTALL_DIR`'LIBDIR}" ]; then confMKDIR -p "${DESTDIR}${bldINSTALL_DIR`'LIBDIR}"; else :; fi ')
++	${INSTALL} -c -o ${LIBOWN} -g ${LIBGRP} -m ${UBINMODE} bldCURRENT_PRODUCT.so "${DESTDIR}${LIBDIR}/bldCURRENT_PRODUCT.so.${MILTER_SOVER}"
++	${LN} ${LNOPTS} bldCURRENT_PRODUCT.so.${MILTER_SOVER} "${DESTDIR}${LIBDIR}/bldCURRENT_PRODUCT.so"
++	${INSTALL} -c -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} bldCURRENT_PRODUCT.a "${DESTDIR}${LIBDIR}"')
++
++bldCURRENT_PRODUCT-clean:
++	rm -f ${OBJS} bldCURRENT_PRODUCT.so bldCURRENT_PRODUCT.a ${MANPAGES}
++
++divert(0)
++COPTS+= confCCOPTS_SO
+diff -Nru sendmail-8.14.3.orig/libmilter/Makefile.m4 sendmail-8.14.3/libmilter/Makefile.m4
+--- sendmail-8.14.3.orig/libmilter/Makefile.m4	2008-04-08 07:23:44.000000000 +0200
++++ sendmail-8.14.3/libmilter/Makefile.m4	2009-08-22 21:53:35.000000000 +0200
+_at_@ -9,7 +9,7 @@
+ SMSRCDIR=ifdef(`confSMSRCDIR', `confSMSRCDIR', `${SRCDIR}/sendmail')
+ PREPENDDEF(`confINCDIRS', `-I${SMSRCDIR} ')
+ 
+-bldPRODUCT_START(`library', `libmilter')
++bldPRODUCT_START(`milterlibrary', `libmilter')
+ define(`bldINSTALLABLE', `true')
+ define(`LIBMILTER_EXTRAS', `errstring.c strl.c')
+ APPENDDEF(`confENVDEF', `-DNOT_SENDMAIL -Dsm_snprintf=snprintf')
-- 
2.7.0
---
Unsubscribe:  alpine-aports+unsubscribe_at_lists.alpinelinux.org
Help:         alpine-aports+help_at_lists.alpinelinux.org
---
Received on Fri Jan 22 2016 - 15:12:14 GMT