init package
crlf to cr modify release
This commit is contained in:
parent
c5dfa92127
commit
c6db81e537
61
0001-remove-libreplace-unneeded-on-Linux.patch
Normal file
61
0001-remove-libreplace-unneeded-on-Linux.patch
Normal file
@ -0,0 +1,61 @@
|
||||
From d559339883f61bfb44188c4fe92851a2905e8a8e Mon Sep 17 00:00:00 2001
|
||||
From: Matt Domsch <mdomsch@fedoraproject.org>
|
||||
Date: Thu, 23 Jan 2014 10:51:07 -0600
|
||||
Subject: [PATCH 1/2] remove libreplace, unneeded on Linux
|
||||
|
||||
---
|
||||
configure.ac | 3 ---
|
||||
src/Makefile.am | 2 +-
|
||||
src/libspf2/Makefile.am | 4 ----
|
||||
3 files changed, 1 insertion(+), 8 deletions(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 63e398c..63e5392 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -273,8 +273,6 @@ AC_CHECK_FUNCS([strchr strcspn strdup strerror])
|
||||
AC_CHECK_FUNCS([strcasecmp strncasecmp strspn strtoul])
|
||||
AC_CHECK_FUNCS([gethostbyname inet_ntoa select strrchr strstr strtol])
|
||||
|
||||
-AC_REPLACE_FUNCS([getopt_long_only strncasecmp])
|
||||
-AC_REPLACE_FUNCS([__ns_initparse __ns_name_uncompress __ns_msg_getflag])
|
||||
dnl Magnus Holmgren says this avoids linking a private function
|
||||
AC_LIBOBJ([__ns_get16])
|
||||
|
||||
@@ -282,7 +280,6 @@ AC_CONFIG_FILES([Makefile
|
||||
Doxyfile
|
||||
src/Makefile
|
||||
src/include/Makefile
|
||||
- src/libreplace/Makefile
|
||||
src/libspf2/Makefile
|
||||
src/spfquery/Makefile
|
||||
src/spftest/Makefile
|
||||
diff --git a/src/Makefile.am b/src/Makefile.am
|
||||
index 307bf10..02f09b4 100644
|
||||
--- a/src/Makefile.am
|
||||
+++ b/src/Makefile.am
|
||||
@@ -4,5 +4,5 @@ AUTOMAKE_OPTIONS = foreign
|
||||
# Attempt to disable parallel processing.
|
||||
.NOTPARALLEL:
|
||||
.NO_PARALLEL:
|
||||
-SUBDIRS = include libreplace libspf2 spfquery spftest spfd spf_example
|
||||
+SUBDIRS = include libspf2 spfquery spftest spfd spf_example
|
||||
TARGETS =
|
||||
diff --git a/src/libspf2/Makefile.am b/src/libspf2/Makefile.am
|
||||
index 6b5a147..77ef3b9 100644
|
||||
--- a/src/libspf2/Makefile.am
|
||||
+++ b/src/libspf2/Makefile.am
|
||||
@@ -34,10 +34,6 @@ libspf2_la_SOURCES = \
|
||||
spf_utils.c \
|
||||
spf_win32.c
|
||||
|
||||
-libspf2_la_LIBADD = $(top_builddir)/src/libreplace/libreplace.la
|
||||
-
|
||||
-
|
||||
-
|
||||
libspf2_la_LDFLAGS = -version-info 3:0:1
|
||||
|
||||
# Copied from the libtool info file:
|
||||
--
|
||||
1.8.4.2
|
||||
|
||||
BIN
libspf2-1.2.11-4915c308.tar.xz
Normal file
BIN
libspf2-1.2.11-4915c308.tar.xz
Normal file
Binary file not shown.
173
libspf2.spec
Normal file
173
libspf2.spec
Normal file
@ -0,0 +1,173 @@
|
||||
%global git 4915c308
|
||||
%{!?_without_checks: %{!?_with_checks: %global _without_checks --without-checks}}
|
||||
%{?_with_checks: %global enable_checks 1}
|
||||
%{?_without_checks: %global enable_checks 0}
|
||||
|
||||
Name: libspf2
|
||||
Version: 1.2.11
|
||||
Release: 1
|
||||
Summary: An implementation of the SPF specification
|
||||
License: BSD or LGPLv2+
|
||||
Url: http://www.libspf2.org/
|
||||
|
||||
Source0: libspf2-%{version}-%{git}.tar.xz
|
||||
Patch1: 0001-remove-libreplace-unneeded-on-Linux.patch
|
||||
|
||||
BuildRequires: gcc
|
||||
BuildRequires: automake autoconf libtool
|
||||
BuildRequires: doxygen, graphviz
|
||||
BuildRequires: perl-devel
|
||||
BuildRequires: perl-generators
|
||||
BuildRequires: perl(ExtUtils::MakeMaker)
|
||||
BuildRequires: make
|
||||
BuildConflicts: perl(Test::Pod::Coverage)
|
||||
BuildConflicts: perl(Mail::SPF::Test)
|
||||
|
||||
%description
|
||||
libspf2 is an implementation of the SPF (Sender Policy Framework)
|
||||
specification as found at:
|
||||
http://www.ietf.org/internet-drafts/draft-mengwong-spf-00.txt
|
||||
SPF allows email systems to check SPF DNS records and make sure that
|
||||
an email is authorized by the administrator of the domain name that
|
||||
it is coming from. This prevents email forgery, commonly used by
|
||||
spammers, scammers, and email viruses/worms.
|
||||
|
||||
A lot of effort has been put into making it secure by design, and a
|
||||
great deal of effort has been put into the regression tests.
|
||||
|
||||
%package devel
|
||||
Summary: Development tools needed to build programs that use libspf2
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
|
||||
%description devel
|
||||
The libspf2-devel package contains the header files necessary for
|
||||
developing programs using the libspf2 (Sender Policy Framework)
|
||||
library.
|
||||
|
||||
If you want to develop programs that will look up and process SPF records,
|
||||
you should install libspf2-devel.
|
||||
|
||||
API documentation is in the separate libspf2-apidocs package.
|
||||
|
||||
%package apidocs
|
||||
Summary: API documentation for the libspf2 library
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
BuildArch: noarch
|
||||
|
||||
%description apidocs
|
||||
The libspf2-apidocs package contains the API documentation for creating
|
||||
applications that use the libspf2 (Sender Policy Framework) library.
|
||||
|
||||
%package -n perl-Mail-SPF_XS
|
||||
Summary: An XS implementation of Mail::SPF
|
||||
License: GPL+ or Artistic
|
||||
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
|
||||
%description -n perl-Mail-SPF_XS
|
||||
This is an interface to the C library libspf2 for the purpose of
|
||||
testing. While it can be used as an SPF implementation, you can also
|
||||
use Mail::SPF, which is a little more perlish.
|
||||
|
||||
%package progs
|
||||
Summary: Programs for making SPF queries using libspf2
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
Requires(post): /usr/sbin/alternatives
|
||||
Requires(preun): /usr/sbin/alternatives
|
||||
Requires(postun): /usr/sbin/alternatives, /usr/bin/readlink
|
||||
|
||||
%description progs
|
||||
Programs for making SPF queries and checking their results using libspf2.
|
||||
|
||||
%prep
|
||||
%setup -q -n libspf2-%{version}-%{git}
|
||||
%patch1 -p1
|
||||
|
||||
|
||||
%build
|
||||
ac_cv_func___ns_get16=no
|
||||
export ac_cv_func___ns_get16
|
||||
|
||||
autoreconf -vif
|
||||
%configure --enable-perl --disable-dependency-tracking
|
||||
|
||||
|
||||
sed -i 's|^sys_lib_dlsearch_path_spec="/lib /usr/lib|sys_lib_dlsearch_path_spec="/%{_lib} %{_libdir}|' libtool
|
||||
|
||||
make %{?_smp_mflags} CFLAGS="%{optflags} -fno-strict-aliasing"
|
||||
|
||||
sed -i -e 's/\(SHORT_NAMES[[:space:]]*=[[:space:]]*\)NO/\1YES/' Doxyfile
|
||||
/usr/bin/doxygen
|
||||
|
||||
%install
|
||||
make \
|
||||
DESTDIR=%{buildroot} \
|
||||
PERL_INSTALL_ROOT=$(grep DESTDIR perl/Makefile &> /dev/null && echo "" || echo %{buildroot}) \
|
||||
INSTALLDIRS=vendor \
|
||||
INSTALL="install -p" \
|
||||
install
|
||||
|
||||
find %{buildroot} \( -name perllocal.pod -o -name .packlist \) -delete
|
||||
find %{buildroot} -type f -name '*.bs' -a -size 0 -delete
|
||||
find %{buildroot} -depth -type d -exec rmdir {} 2>/dev/null ';'
|
||||
chmod -R u+w %{buildroot}/*
|
||||
rm -f %{buildroot}%{_bindir}/spf*_static
|
||||
mv -f %{buildroot}%{_bindir}/spfquery %{buildroot}%{_bindir}/spfquery.libspf2
|
||||
mv -f %{buildroot}%{_bindir}/spfd %{buildroot}%{_bindir}/spfd.libspf2
|
||||
rm -rf %{buildroot}%{_libdir}/*.a
|
||||
rm -rf %{buildroot}%{_libdir}/*.la
|
||||
|
||||
%check
|
||||
%if %{enable_checks}
|
||||
make -C tests check
|
||||
LD_PRELOAD=$(pwd)/src/libspf2/.libs/libspf2.so make -C perl test
|
||||
%endif
|
||||
|
||||
%ldconfig_scriptlets
|
||||
|
||||
%post progs
|
||||
/usr/sbin/alternatives --install %{_bindir}/spfquery spf %{_bindir}/spfquery.libspf2 20 \
|
||||
--slave %{_bindir}/spfd spf-daemon %{_bindir}/spfd.libspf2
|
||||
exit 0
|
||||
|
||||
%preun progs
|
||||
if [ $1 = 0 ]; then
|
||||
/usr/sbin/alternatives --remove spf %{_bindir}/spfquery.libspf2
|
||||
fi
|
||||
exit 0
|
||||
|
||||
%postun progs
|
||||
if [ "$1" -ge "1" ]; then
|
||||
spf=`readlink /etc/alternatives/spf`
|
||||
if [ "$spf" == "%{_bindir}/spfquery.libspf2" ]; then
|
||||
/usr/sbin/alternatives --set spf %{_bindir}/spfquery.libspf2
|
||||
fi
|
||||
fi
|
||||
exit 0
|
||||
|
||||
%files
|
||||
%license LICENSES
|
||||
%doc README INSTALL
|
||||
%{_libdir}/libspf2.so.*
|
||||
|
||||
%files devel
|
||||
%{_includedir}/spf2/
|
||||
%{_libdir}/libspf2.so
|
||||
|
||||
%files apidocs
|
||||
%doc doxygen/html
|
||||
|
||||
%files progs
|
||||
%{_bindir}/spfd.libspf2
|
||||
%{_bindir}/spfquery.libspf2
|
||||
%{_bindir}/spftest
|
||||
%{_bindir}/spf_example
|
||||
|
||||
%files -n perl-Mail-SPF_XS
|
||||
%{perl_vendorarch}/Mail/
|
||||
%{perl_vendorarch}/auto/Mail/
|
||||
%{_mandir}/man3/Mail::SPF_XS.3pm*
|
||||
|
||||
%changelog
|
||||
* Tue Oct 18 2022 openEuler Application <dev@openeuler.org> - 1.2.11-1
|
||||
- DESC:Package init
|
||||
1
libspf2.yaml
Normal file
1
libspf2.yaml
Normal file
@ -0,0 +1 @@
|
||||
version_control: github
src_repo: shevek/libspf2
tag_prefix: ^v
seperator: .
|
||||
Loading…
x
Reference in New Issue
Block a user