|
|
@ -4,8 +4,8 @@
|
|
|
|
%{!?__global_ldflags: %global __global_ldflags -Wl,-z,relro}
|
|
|
|
%{!?__global_ldflags: %global __global_ldflags -Wl,-z,relro}
|
|
|
|
|
|
|
|
|
|
|
|
Name: tss2
|
|
|
|
Name: tss2
|
|
|
|
Version: 1234
|
|
|
|
Version: 1331
|
|
|
|
Release: 5%{?dist}
|
|
|
|
Release: 2%{?dist}
|
|
|
|
Summary: IBM's TCG Software Stack (TSS) for TPM 2.0 and related utilities
|
|
|
|
Summary: IBM's TCG Software Stack (TSS) for TPM 2.0 and related utilities
|
|
|
|
|
|
|
|
|
|
|
|
Group: Applications/System
|
|
|
|
Group: Applications/System
|
|
|
@ -13,17 +13,13 @@ License: BSD
|
|
|
|
URL: http://sourceforge.net/projects/ibmtpm20tss/
|
|
|
|
URL: http://sourceforge.net/projects/ibmtpm20tss/
|
|
|
|
Source0: https://sourceforge.net/projects/ibmtpm20tss/files/ibmtss%{version}.tar.gz
|
|
|
|
Source0: https://sourceforge.net/projects/ibmtpm20tss/files/ibmtss%{version}.tar.gz
|
|
|
|
|
|
|
|
|
|
|
|
Patch0: 0001-ekutils-fix-null-check-in-convertPemToX509.patch
|
|
|
|
|
|
|
|
Patch1: 0002-ektuils-check-return-of-X509_gmtime_adj-for-notAfter.patch
|
|
|
|
|
|
|
|
Patch2: 0003-imalib-call-memcmp-with-correct-size.patch
|
|
|
|
|
|
|
|
Patch3: 0004-certifycreation-Check-that-creation-hash-file-name-r.patch
|
|
|
|
|
|
|
|
Patch4: flags-fixup.patch
|
|
|
|
Patch4: flags-fixup.patch
|
|
|
|
Patch5: header-file.patch
|
|
|
|
|
|
|
|
# reported upstream https://sourceforge.net/p/ibmtpm20tss/mailman/message/36444738/
|
|
|
|
# reported upstream https://sourceforge.net/p/ibmtpm20tss/mailman/message/36444738/
|
|
|
|
# and reported fixed, but not yet pushed to sourceforge.
|
|
|
|
# and reported fixed, but not yet pushed to sourceforge.
|
|
|
|
Patch6: hash_generate.patch
|
|
|
|
Patch5: hash_generate.patch
|
|
|
|
|
|
|
|
# Submitted upstream
|
|
|
|
|
|
|
|
Patch6: 0001-tss2-fix-bounds-check-in-IMA_Event_PcrExtend.patch
|
|
|
|
|
|
|
|
|
|
|
|
BuildRequires: help2man
|
|
|
|
|
|
|
|
BuildRequires: openssl-devel
|
|
|
|
BuildRequires: openssl-devel
|
|
|
|
BuildRequires: gcc
|
|
|
|
BuildRequires: gcc
|
|
|
|
Requires: openssl
|
|
|
|
Requires: openssl
|
|
|
@ -49,14 +45,7 @@ order to build TSS 2.0 applications.
|
|
|
|
%define incname ibmtss
|
|
|
|
%define incname ibmtss
|
|
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%prep
|
|
|
|
%setup -q -c %{name}-%{version}
|
|
|
|
%autosetup -p1 -c %{name}-%{version}
|
|
|
|
%patch0 -p1
|
|
|
|
|
|
|
|
%patch1 -p1
|
|
|
|
|
|
|
|
%patch2 -p1
|
|
|
|
|
|
|
|
%patch3 -p1
|
|
|
|
|
|
|
|
%patch4 -p1
|
|
|
|
|
|
|
|
%patch5 -p1
|
|
|
|
|
|
|
|
%patch6 -p1
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
%build
|
|
|
|
# nonstandard variable names are used in place of CFLAGS and LDFLAGS
|
|
|
|
# nonstandard variable names are used in place of CFLAGS and LDFLAGS
|
|
|
@ -64,21 +53,6 @@ pushd utils
|
|
|
|
CCFLAGS="%{optflags}" \
|
|
|
|
CCFLAGS="%{optflags}" \
|
|
|
|
LNFLAGS="%{__global_ldflags}" \
|
|
|
|
LNFLAGS="%{__global_ldflags}" \
|
|
|
|
make -f makefile.fedora %{?_smp_mflags}
|
|
|
|
make -f makefile.fedora %{?_smp_mflags}
|
|
|
|
|
|
|
|
|
|
|
|
# Generate man pages for extracted list of executables
|
|
|
|
|
|
|
|
mkdir -p man/man1
|
|
|
|
|
|
|
|
BIN_PREFIX=tss
|
|
|
|
|
|
|
|
man_exe=$(sed -n "s,^help2man.*/usr/bin/${BIN_PREFIX}\\([^ ]*\) .*\$,\\1,p" makeman.sh)
|
|
|
|
|
|
|
|
for f in $man_exe; do
|
|
|
|
|
|
|
|
# prefixed name
|
|
|
|
|
|
|
|
n=${BIN_PREFIX}$f
|
|
|
|
|
|
|
|
# extract description of binary
|
|
|
|
|
|
|
|
desc=$(sed -n -e "s,^help2man.* -n \"\\([^\"]*\\)\".*/usr/bin/$n .*\$,\\1,p" makeman.sh)
|
|
|
|
|
|
|
|
# temporarily link executable to prefixed name so man page is generated with correct name
|
|
|
|
|
|
|
|
ln -s $PWD/$f %{_tmppath}/$n
|
|
|
|
|
|
|
|
LD_LIBRARY_PATH="$PWD:$LD_LIBRARY_PATH" help2man -h-h --version-string="v%{version}" -n "$desc" %{_tmppath}/$n > man/man1/$n.1
|
|
|
|
|
|
|
|
rm %{_tmppath}/$n
|
|
|
|
|
|
|
|
done
|
|
|
|
|
|
|
|
popd
|
|
|
|
popd
|
|
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
%install
|
|
|
@ -95,7 +69,7 @@ for f in *; do
|
|
|
|
cp -p $f %{buildroot}/%{_bindir}/${BIN_PREFIX}$f
|
|
|
|
cp -p $f %{buildroot}/%{_bindir}/${BIN_PREFIX}$f
|
|
|
|
fi;
|
|
|
|
fi;
|
|
|
|
done
|
|
|
|
done
|
|
|
|
cp -p *.so.0.1 %{buildroot}/%{_libdir}
|
|
|
|
cp -p *.so.1.1 %{buildroot}/%{_libdir}
|
|
|
|
cp -p %{incname}/*.h %{buildroot}/%{_includedir}/%{incname}/
|
|
|
|
cp -p %{incname}/*.h %{buildroot}/%{_includedir}/%{incname}/
|
|
|
|
cp -p man/man1/tss*.1 %{buildroot}/%{_mandir}/man1/
|
|
|
|
cp -p man/man1/tss*.1 %{buildroot}/%{_mandir}/man1/
|
|
|
|
popd
|
|
|
|
popd
|
|
|
@ -103,10 +77,10 @@ popd
|
|
|
|
|
|
|
|
|
|
|
|
# Make symbolic links to the shared lib
|
|
|
|
# Make symbolic links to the shared lib
|
|
|
|
pushd %{buildroot}/%{_libdir}
|
|
|
|
pushd %{buildroot}/%{_libdir}
|
|
|
|
rm -f libibmtss.so.0
|
|
|
|
rm -f libibmtss.so.1
|
|
|
|
ln -sf libibmtss.so.0.1 libibmtss.so.0
|
|
|
|
ln -sf libibmtss.so.1.1 libibmtss.so.1
|
|
|
|
rm -f libibmtss.so
|
|
|
|
rm -f libibmtss.so
|
|
|
|
ln -sf libibmtss.so.0 libibmtss.so
|
|
|
|
ln -sf libibmtss.so.1 libibmtss.so
|
|
|
|
popd
|
|
|
|
popd
|
|
|
|
|
|
|
|
|
|
|
|
%post -p /sbin/ldconfig
|
|
|
|
%post -p /sbin/ldconfig
|
|
|
@ -115,8 +89,8 @@ popd
|
|
|
|
%files
|
|
|
|
%files
|
|
|
|
%license LICENSE
|
|
|
|
%license LICENSE
|
|
|
|
%{_bindir}/tss*
|
|
|
|
%{_bindir}/tss*
|
|
|
|
%{_libdir}/libibmtss.so.0
|
|
|
|
%{_libdir}/libibmtss.so.1
|
|
|
|
%{_libdir}/libibmtss.so.0.*
|
|
|
|
%{_libdir}/libibmtss.so.1.*
|
|
|
|
%attr(0644, root, root) %{_mandir}/man1/tss*.1*
|
|
|
|
%attr(0644, root, root) %{_mandir}/man1/tss*.1*
|
|
|
|
|
|
|
|
|
|
|
|
%files devel
|
|
|
|
%files devel
|
|
|
@ -125,6 +99,15 @@ popd
|
|
|
|
%doc ibmtss.doc
|
|
|
|
%doc ibmtss.doc
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
%changelog
|
|
|
|
|
|
|
|
* Thu Jun 06 2019 Jerry Snitselaar <jsnitsel@redhat.com> - 1331-2
|
|
|
|
|
|
|
|
- Fix bounds check in IMA_Event_PcrExtend
|
|
|
|
|
|
|
|
resolves: rhbz#1669239
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Thu May 30 2019 Jerry Snitselaar <jsnitsel@redhat.com> - 1331-1
|
|
|
|
|
|
|
|
- Rebase to v1331
|
|
|
|
|
|
|
|
- Add initial CI gating support
|
|
|
|
|
|
|
|
resolves: rhbz#1669239
|
|
|
|
|
|
|
|
|
|
|
|
* Fri Oct 05 2018 Jerry Snitselaar <jsnitsel@redhat.com> - 1234-5
|
|
|
|
* Fri Oct 05 2018 Jerry Snitselaar <jsnitsel@redhat.com> - 1234-5
|
|
|
|
- Move header files to ibmtss directory.
|
|
|
|
- Move header files to ibmtss directory.
|
|
|
|
- Check return value of TSS_Hash_Generate.
|
|
|
|
- Check return value of TSS_Hash_Generate.
|
|
|
|