diff --git a/expect.changes b/expect.changes index 63ec681..45c281b 100644 --- a/expect.changes +++ b/expect.changes @@ -1,3 +1,13 @@ +------------------------------------------------------------------- +Wed Apr 21 13:13:28 UTC 2021 - Matthias Gerstner + +- pass explicit -pie flag to CFLAGS and hack `make` invocation so that + /usr/bin/expect actually becomes a PIE binary. This is especially awkard + since the expect build system implicitly passes -fPIC which breaks our + gcc-PIE package, but does not pass -pie while linking the executable. + Shared libraries are also not linked with -shared so we need to explicitly + pass this, too, to avoid build breakage (bsc#1184122). + ------------------------------------------------------------------- Thu Oct 15 08:18:32 UTC 2020 - Reinhard Max diff --git a/expect.spec b/expect.spec index 2073b34..af317b0 100644 --- a/expect.spec +++ b/expect.spec @@ -1,7 +1,7 @@ # # spec file for package expect # -# Copyright (c) 2020 SUSE LLC +# Copyright (c) 2021 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -59,13 +59,14 @@ expect package loaded. %patch4 %build +export CFLAGS="%{optflags} -fPIC -pie" autoreconf %configure \ --with-tcl=%_libdir \ --with-tk=no_tk \ --with-tclinclude=%_includedir \ --enable-shared -make %{?_smp_mflags} all pkglibdir=%_libdir/tcl/%name%version +make SHLIB_CFLAGS="-shared" %{?_smp_mflags} all pkglibdir=%_libdir/tcl/%name%version %check make %{?_smp_mflags} test