This adds support for "make rpm"
This commit is contained in:
parent
f3b14343a5
commit
1be873533e
10
Makefile.am
10
Makefile.am
@ -15,13 +15,10 @@ check_PROGRAMS =
|
||||
EXTRA_HEADERS =
|
||||
BUILT_SOURCES=
|
||||
EXTRA_DIST=
|
||||
doc_DATA=
|
||||
dist_doc_DATA=
|
||||
|
||||
exampledir = $(docdir)/@PACKAGE@/example
|
||||
example_DATA=
|
||||
EXTRA_DIST+= $(example_DATA)
|
||||
|
||||
EXTRA_DIST+= $(doc_DATA)
|
||||
exampledir = $(docdir)/example
|
||||
dist_example_DATA=
|
||||
|
||||
ACLOCAL_AMFLAGS= -I m4
|
||||
|
||||
@ -50,6 +47,7 @@ include examples/echoserver/include.am
|
||||
include testsuite/include.am
|
||||
include tests/include.am
|
||||
include sslSniffer/sslSnifferTest/include.am
|
||||
include rpm/include.am
|
||||
|
||||
TESTS += $(check_PROGRAMS)
|
||||
test: check
|
||||
|
@ -34,7 +34,7 @@ EXTRA_DIST += \
|
||||
certs/ecc-key.der
|
||||
|
||||
|
||||
doc_DATA+= certs/taoCert.txt
|
||||
dist_doc_DATA+= certs/taoCert.txt
|
||||
|
||||
EXTRA_DIST+= certs/ntru-key.raw
|
||||
|
||||
|
@ -692,6 +692,7 @@ AC_CONFIG_FILES([stamp-h], [echo timestamp > stamp-h])
|
||||
AC_CONFIG_FILES([Makefile])
|
||||
AC_CONFIG_FILES([cyassl/version.h])
|
||||
AC_CONFIG_FILES([support/libcyassl.pc])
|
||||
AC_CONFIG_FILES([rpm/spec])
|
||||
|
||||
AC_OUTPUT
|
||||
|
||||
|
@ -2,4 +2,4 @@
|
||||
# included from Top Level Makefile.am
|
||||
# All paths should be given relative to the root
|
||||
|
||||
doc_DATA+= doc/README.txt
|
||||
dist_doc_DATA+= doc/README.txt
|
||||
|
@ -10,4 +10,4 @@ EXTRA_DIST += examples/client/client.sln
|
||||
EXTRA_DIST += examples/client/client-ntru.vcproj
|
||||
EXTRA_DIST += examples/client/client.vcproj
|
||||
|
||||
example_DATA+= examples/client/client.c
|
||||
dist_example_DATA+= examples/client/client.c
|
||||
|
@ -12,4 +12,4 @@ EXTRA_DIST += examples/echoclient/echoclient.sln
|
||||
EXTRA_DIST += examples/echoclient/echoclient-ntru.vcproj
|
||||
EXTRA_DIST += examples/echoclient/echoclient.vcproj
|
||||
|
||||
example_DATA+= examples/echoclient/echoclient.c
|
||||
dist_example_DATA+= examples/echoclient/echoclient.c
|
||||
|
@ -12,4 +12,4 @@ EXTRA_DIST += examples/echoserver/echoserver.sln
|
||||
EXTRA_DIST += examples/echoserver/echoserver-ntru.vcproj
|
||||
EXTRA_DIST += examples/echoserver/echoserver.vcproj
|
||||
|
||||
example_DATA+= examples/echoserver/echoserver.c
|
||||
dist_example_DATA+= examples/echoserver/echoserver.c
|
||||
|
@ -12,4 +12,4 @@ EXTRA_DIST += examples/server/server.sln
|
||||
EXTRA_DIST += examples/server/server-ntru.vcproj
|
||||
EXTRA_DIST += examples/server/server.vcproj
|
||||
|
||||
example_DATA+= examples/server/server.c
|
||||
dist_example_DATA+= examples/server/server.c
|
||||
|
@ -70,10 +70,12 @@
|
||||
|
||||
ax_append_compile_link_flags_extra=
|
||||
AS_IF([test "$ac_cv_vcs_checkout" = "yes"], [
|
||||
AX_CHECK_LINK_FLAG([-Werror])
|
||||
],[
|
||||
AX_CHECK_LINK_FLAG([-Werror],[ax_append_compile_link_flags_extra])
|
||||
AX_CHECK_LINK_FLAG([-Werror])
|
||||
],[
|
||||
AX_CHECK_LINK_FLAG([-Werror],[
|
||||
ax_append_compile_link_flags_extra=$ax_cv_check_ldflags___Werror
|
||||
])
|
||||
])
|
||||
AX_CHECK_LINK_FLAG([-z relro -z now],,[$ax_append_compile_link_flags_extra])
|
||||
AX_CHECK_LINK_FLAG([-pie],,[$ax_append_compile_link_flags_extra])
|
||||
])
|
||||
|
37
rpm/include.am
Normal file
37
rpm/include.am
Normal file
@ -0,0 +1,37 @@
|
||||
# vim:ft=automake
|
||||
|
||||
rpm-build: rpm/spec dist
|
||||
@rm -f *.rpm
|
||||
@rm -f ~/rpmbuild/RPMS/x86_64/$(PACKAGE)-$(VERSION)*.rpm
|
||||
@rm -f ~/rpmbuild/SRPMS/$(PACKAGE)-$(VERSION)*.rpm
|
||||
@mkdir -p ~/rpmbuild/BUILD/
|
||||
@mkdir -p ~/rpmbuild/RPMS/i386/
|
||||
@mkdir -p ~/rpmbuild/RPMS/i686/
|
||||
@mkdir -p ~/rpmbuild/RPMS/noarch/
|
||||
@mkdir -p ~/rpmbuild/RPMS/x86_64/
|
||||
@mkdir -p ~/rpmbuild/SOURCES/
|
||||
@mkdir -p ~/rpmbuild/SPECS/
|
||||
@mkdir -p ~/rpmbuild/SRPMS/
|
||||
@cp $(PACKAGE)-$(VERSION).tar.gz ~/rpmbuild/SOURCES/
|
||||
@rpmbuild -ba --clean rpm/spec
|
||||
@cp ~/rpmbuild/RPMS/x86_64/$(PACKAGE)-$(VERSION)*.rpm .
|
||||
@cp ~/rpmbuild/RPMS/x86_64/$(PACKAGE)-devel-$(VERSION)*.rpm .
|
||||
@cp ~/rpmbuild/RPMS/x86_64/$(PACKAGE)-debuginfo-$(VERSION)*.rpm .
|
||||
@cp ~/rpmbuild/SRPMS/$(PACKAGE)-$(VERSION)*.rpm .
|
||||
|
||||
rpm-sign: rpm-build
|
||||
@rpm --addsign *.rpm
|
||||
@rpm --checksig *.rpm
|
||||
|
||||
clean-rpm:
|
||||
@rm -f *.tar.gz
|
||||
@rm -f *.src.rpm
|
||||
@rm -f *.rpm
|
||||
|
||||
rpm: rpm-build
|
||||
|
||||
release: rpm-sign
|
||||
|
||||
auto-rpmbuild:
|
||||
@auto-br-rpmbuild -ba rpm/spec
|
||||
|
144
rpm/spec.in
Normal file
144
rpm/spec.in
Normal file
@ -0,0 +1,144 @@
|
||||
Summary: Embedded SSL Library
|
||||
Name: @PACKAGE@
|
||||
Version: @VERSION@
|
||||
Release: 1
|
||||
License: BSD
|
||||
Group: System Environment/Libraries
|
||||
BuildRequires: bison
|
||||
URL: http://www.yassl.com/yaSSL/Home.html
|
||||
|
||||
Packager: Brian Aker <brian@tangent.org>
|
||||
|
||||
Source: http://yassl.com/yaSSL/download/%{name}-%{version}.tar.gz
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
|
||||
|
||||
%description
|
||||
Misc tools for Yassl.
|
||||
|
||||
%package devel
|
||||
Summary: Header files and development libraries for %{name}
|
||||
Group: Development/Libraries
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
|
||||
%description devel
|
||||
This package contains the header files and development libraries
|
||||
for %{name}. If you like to develop programs using %{name},
|
||||
you will need to install %{name}-devel.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
|
||||
%configure
|
||||
|
||||
|
||||
%build
|
||||
%{__make} %{?_smp_mflags}
|
||||
|
||||
%install
|
||||
%{__rm} -rf %{buildroot}
|
||||
%{__make} install DESTDIR="%{buildroot}" AM_INSTALL_PROGRAM_FLAGS=""
|
||||
mkdir -p $RPM_BUILD_ROOT/
|
||||
|
||||
%check
|
||||
|
||||
|
||||
%clean
|
||||
%{__rm} -rf %{buildroot}
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%doc AUTHORS ChangeLog COPYING NEWS README
|
||||
%{_docdir}/cyassl/taoCert.txt
|
||||
%{_docdir}/cyassl/example/echoserver.c
|
||||
%{_docdir}/cyassl/example/server.c
|
||||
%{_docdir}/cyassl/example/echoclient.c
|
||||
%{_docdir}/cyassl/example/client.c
|
||||
%{_docdir}/cyassl/README.txt
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root,-)
|
||||
%doc AUTHORS ChangeLog COPYING NEWS README
|
||||
%{_libdir}/libcyassl.a
|
||||
%{_libdir}/libcyassl.la
|
||||
%{_libdir}/libcyassl.so
|
||||
%{_libdir}/libcyassl.so.3
|
||||
%{_libdir}/libcyassl.so.3.0.3
|
||||
%{_includedir}/cyassl/callbacks.h
|
||||
%{_includedir}/cyassl/crl.h
|
||||
%{_includedir}/cyassl/ctaocrypt/aes.h
|
||||
%{_includedir}/cyassl/ctaocrypt/arc4.h
|
||||
%{_includedir}/cyassl/ctaocrypt/asn.h
|
||||
%{_includedir}/cyassl/ctaocrypt/asn_public.h
|
||||
%{_includedir}/cyassl/ctaocrypt/coding.h
|
||||
%{_includedir}/cyassl/ctaocrypt/des3.h
|
||||
%{_includedir}/cyassl/ctaocrypt/dh.h
|
||||
%{_includedir}/cyassl/ctaocrypt/dsa.h
|
||||
%{_includedir}/cyassl/ctaocrypt/ecc.h
|
||||
%{_includedir}/cyassl/ctaocrypt/error.h
|
||||
%{_includedir}/cyassl/ctaocrypt/hc128.h
|
||||
%{_includedir}/cyassl/ctaocrypt/hmac.h
|
||||
%{_includedir}/cyassl/ctaocrypt/integer.h
|
||||
%{_includedir}/cyassl/ctaocrypt/logging.h
|
||||
%{_includedir}/cyassl/ctaocrypt/md2.h
|
||||
%{_includedir}/cyassl/ctaocrypt/md4.h
|
||||
%{_includedir}/cyassl/ctaocrypt/md5.h
|
||||
%{_includedir}/cyassl/ctaocrypt/memory.h
|
||||
%{_includedir}/cyassl/ctaocrypt/misc.h
|
||||
%{_includedir}/cyassl/ctaocrypt/mpi_class.h
|
||||
%{_includedir}/cyassl/ctaocrypt/mpi_superclass.h
|
||||
%{_includedir}/cyassl/ctaocrypt/pwdbased.h
|
||||
%{_includedir}/cyassl/ctaocrypt/rabbit.h
|
||||
%{_includedir}/cyassl/ctaocrypt/random.h
|
||||
%{_includedir}/cyassl/ctaocrypt/ripemd.h
|
||||
%{_includedir}/cyassl/ctaocrypt/rsa.h
|
||||
%{_includedir}/cyassl/ctaocrypt/settings.h
|
||||
%{_includedir}/cyassl/ctaocrypt/sha.h
|
||||
%{_includedir}/cyassl/ctaocrypt/sha256.h
|
||||
%{_includedir}/cyassl/ctaocrypt/sha512.h
|
||||
%{_includedir}/cyassl/ctaocrypt/tfm.h
|
||||
%{_includedir}/cyassl/ctaocrypt/types.h
|
||||
%{_includedir}/cyassl/ctaocrypt/visibility.h
|
||||
%{_includedir}/cyassl/error.h
|
||||
%{_includedir}/cyassl/internal.h
|
||||
%{_includedir}/cyassl/ocsp.h
|
||||
%{_includedir}/cyassl/openssl/asn1.h
|
||||
%{_includedir}/cyassl/openssl/bio.h
|
||||
%{_includedir}/cyassl/openssl/bn.h
|
||||
%{_includedir}/cyassl/openssl/conf.h
|
||||
%{_includedir}/cyassl/openssl/crypto.h
|
||||
%{_includedir}/cyassl/openssl/des.h
|
||||
%{_includedir}/cyassl/openssl/dh.h
|
||||
%{_includedir}/cyassl/openssl/dsa.h
|
||||
%{_includedir}/cyassl/openssl/ec.h
|
||||
%{_includedir}/cyassl/openssl/ecdsa.h
|
||||
%{_includedir}/cyassl/openssl/engine.h
|
||||
%{_includedir}/cyassl/openssl/err.h
|
||||
%{_includedir}/cyassl/openssl/evp.h
|
||||
%{_includedir}/cyassl/openssl/hmac.h
|
||||
%{_includedir}/cyassl/openssl/lhash.h
|
||||
%{_includedir}/cyassl/openssl/md4.h
|
||||
%{_includedir}/cyassl/openssl/md5.h
|
||||
%{_includedir}/cyassl/openssl/ocsp.h
|
||||
%{_includedir}/cyassl/openssl/opensslconf.h
|
||||
%{_includedir}/cyassl/openssl/opensslv.h
|
||||
%{_includedir}/cyassl/openssl/ossl_typ.h
|
||||
%{_includedir}/cyassl/openssl/pem.h
|
||||
%{_includedir}/cyassl/openssl/pkcs12.h
|
||||
%{_includedir}/cyassl/openssl/rand.h
|
||||
%{_includedir}/cyassl/openssl/ripemd.h
|
||||
%{_includedir}/cyassl/openssl/rsa.h
|
||||
%{_includedir}/cyassl/openssl/sha.h
|
||||
%{_includedir}/cyassl/openssl/ssl.h
|
||||
%{_includedir}/cyassl/openssl/stack.h
|
||||
%{_includedir}/cyassl/openssl/ui.h
|
||||
%{_includedir}/cyassl/openssl/x509.h
|
||||
%{_includedir}/cyassl/openssl/x509v3.h
|
||||
%{_includedir}/cyassl/sniffer.h
|
||||
%{_includedir}/cyassl/sniffer_error.h
|
||||
%{_includedir}/cyassl/ssl.h
|
||||
%{_includedir}/cyassl/test.h
|
||||
%{_includedir}/cyassl/version.h
|
||||
|
||||
%changelog
|
||||
* Fri Oct 20 2012 Brian Aker <brian@tangent.org> - 0.1-1
|
||||
- Initial package
|
Loading…
Reference in New Issue
Block a user