Accepting request 455651 from Base:System
1 OBS-URL: https://build.opensuse.org/request/show/455651 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/efivar?expand=0&rev=7
This commit is contained in:
commit
4cbed7df9b
25
efivar-use-sysmacros.patch
Normal file
25
efivar-use-sysmacros.patch
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
From 3ad5aab6ec57b28e62625bf6f3e444b0bcde799a Mon Sep 17 00:00:00 2001
|
||||||
|
From: Peter Jones <pjones@redhat.com>
|
||||||
|
Date: Wed, 10 Aug 2016 16:47:41 -0400
|
||||||
|
Subject: [PATCH] libefivar: use sysmacros.h
|
||||||
|
|
||||||
|
Signed-off-by: Peter Jones <pjones@redhat.com>
|
||||||
|
---
|
||||||
|
src/linux.c | 1 +
|
||||||
|
1 file changed, 1 insertion(+)
|
||||||
|
|
||||||
|
diff --git a/src/linux.c b/src/linux.c
|
||||||
|
index 87f2284..7c644ed 100644
|
||||||
|
--- a/src/linux.c
|
||||||
|
+++ b/src/linux.c
|
||||||
|
@@ -31,6 +31,7 @@
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <sys/ioctl.h>
|
||||||
|
#include <sys/socket.h>
|
||||||
|
+#include <sys/sysmacros.h>
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <sys/param.h>
|
||||||
|
#include <sys/stat.h>
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
@ -1,3 +1,16 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Feb 9 06:32:10 UTC 2017 - glin@suse.com
|
||||||
|
|
||||||
|
- Add efivar-use-sysmacros.patch to fix the Factory/Tumbleweed
|
||||||
|
build correctly.
|
||||||
|
- Amend the spec file to specify the gcc version for SLE11SP4
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Feb 6 14:40:25 UTC 2017 - rw@suse.com
|
||||||
|
|
||||||
|
- Fix building for SLE11SP4, SLE12SP2, and Tumbleweed
|
||||||
|
(fate#322108, bnc#1012765)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Jul 13 03:54:20 UTC 2016 - glin@suse.com
|
Wed Jul 13 03:54:20 UTC 2016 - glin@suse.com
|
||||||
|
|
||||||
|
54
efivar.spec
54
efivar.spec
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package efivar
|
# spec file for package efivar
|
||||||
#
|
#
|
||||||
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
|
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -16,6 +16,17 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
|
%if 0%{?suse_version} <= 1320
|
||||||
|
# Allow building on older products (SLE11SP4, SLES12, and Leap 42.2)
|
||||||
|
%bcond_without forced_lto
|
||||||
|
%if 0%{?suse_version} == 1110
|
||||||
|
%define gcc 48
|
||||||
|
%define gcc_v 4.8
|
||||||
|
%endif
|
||||||
|
%else
|
||||||
|
%bcond_with forced_lto
|
||||||
|
%endif
|
||||||
|
|
||||||
Name: efivar
|
Name: efivar
|
||||||
Version: 0.24
|
Version: 0.24
|
||||||
Release: 0
|
Release: 0
|
||||||
@ -26,9 +37,17 @@ Url: https://github.com/rhinstaller/efivar
|
|||||||
Source0: https://github.com/rhinstaller/efivar/releases/download/%{version}/%{name}-%{version}.tar.bz2
|
Source0: https://github.com/rhinstaller/efivar/releases/download/%{version}/%{name}-%{version}.tar.bz2
|
||||||
Patch1: efivar-no-static.patch
|
Patch1: efivar-no-static.patch
|
||||||
Patch2: deprecated-readdir_r.patch
|
Patch2: deprecated-readdir_r.patch
|
||||||
|
Patch3: efivar-use-sysmacros.patch
|
||||||
|
%if "0%{?buildroot}" == "0"
|
||||||
|
# set a sane value for buildroot, unless it's already there!
|
||||||
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
|
%endif
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: pkg-config
|
BuildRequires: pkg-config
|
||||||
BuildRequires: popt-devel
|
BuildRequires: popt-devel
|
||||||
|
%if 0%{?gcc} != 0
|
||||||
|
BuildRequires: gcc%{gcc}
|
||||||
|
%endif
|
||||||
Requires: libefivar0 = %{version}-%{release}
|
Requires: libefivar0 = %{version}-%{release}
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@ -47,21 +66,48 @@ Group: Development/Libraries/Other
|
|||||||
Requires: libefivar0 = %{version}-%{release}
|
Requires: libefivar0 = %{version}-%{release}
|
||||||
|
|
||||||
%description devel
|
%description devel
|
||||||
development headers required to use libefivar.
|
Development headers required to use libefivar.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
%patch1 -p1
|
%patch1 -p1
|
||||||
%patch2 -p1
|
%patch2 -p1
|
||||||
|
%patch3 -p1
|
||||||
|
%if 0%{?suse_version} == 1110
|
||||||
|
# Instead of conditional patching:
|
||||||
|
# - 'popt.pc' missing in 'popt-devel' on SLE11
|
||||||
|
perl -pi -e 's{^.*PKGS=popt.*$}{}; s{(efivar\S* : LIBS=.*)dl}{$1popt dl}' \
|
||||||
|
src/Makefile
|
||||||
|
# - 'uchar.h' missing in both 'glibc-devel' and 'gcc-5' packages on SLE11
|
||||||
|
perl -pi -e 's{\#include \<uchar\.h\>}{typedef __CHAR16_TYPE__ char16_t;}' \
|
||||||
|
src/export.c
|
||||||
|
%endif
|
||||||
|
|
||||||
%build
|
%build
|
||||||
export CFLAGS="%{optflags} -Wno-nonnull"
|
CFLAGS="%{optflags} -Wno-nonnull"
|
||||||
|
%if %{with forced_lto}
|
||||||
|
CFLAGS="$CFLAGS -flto"
|
||||||
|
%endif
|
||||||
|
%ifarch ia64
|
||||||
|
CFLAGS="${CFLAGS//-fstack-protector/}"
|
||||||
|
%endif
|
||||||
|
export CFLAGS
|
||||||
|
|
||||||
make \
|
make \
|
||||||
|
%if 0%{?suse_version} == 1110
|
||||||
|
CC=gcc-%{gcc_v} \
|
||||||
|
AR=gcc-ar-%{gcc_v} \
|
||||||
|
NM=gcc-nm-%{gcc_v} \
|
||||||
|
RANLIB=gcc-ranlib-%{gcc_v} \
|
||||||
|
%endif
|
||||||
libdir=%{_libdir} \
|
libdir=%{_libdir} \
|
||||||
bindir=%{_bindir}
|
bindir=%{_bindir}
|
||||||
|
|
||||||
%install
|
%install
|
||||||
make DESTDIR=%{buildroot} libdir=%{_libdir} install
|
make DESTDIR=%{buildroot} \
|
||||||
|
libdir=%{_libdir} \
|
||||||
|
bindir=%{_bindir} \
|
||||||
|
install
|
||||||
%fdupes -s %{buildroot}
|
%fdupes -s %{buildroot}
|
||||||
|
|
||||||
%post -n libefivar0 -p /sbin/ldconfig
|
%post -n libefivar0 -p /sbin/ldconfig
|
||||||
|
Loading…
x
Reference in New Issue
Block a user