svn ver. 1158
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
This commit is contained in:
parent
6b3e58e1b2
commit
b85974cf4b
1
.gitignore
vendored
1
.gitignore
vendored
@ -1 +1,2 @@
|
|||||||
flashrom-0.9.2.tar.bz2
|
flashrom-0.9.2.tar.bz2
|
||||||
|
/flashrom-0.9.2.tar.bz2
|
||||||
|
60
flashrom-0001-Define-dmidecode-path-at-a-build-stage.patch
Normal file
60
flashrom-0001-Define-dmidecode-path-at-a-build-stage.patch
Normal file
@ -0,0 +1,60 @@
|
|||||||
|
From 6023a9545efc976e37cc3e2444cdc7c18d987f8d Mon Sep 17 00:00:00 2001
|
||||||
|
From: Peter Lemenkov <lemenkov@gmail.com>
|
||||||
|
Date: Sat, 12 Jun 2010 22:13:53 +0400
|
||||||
|
Subject: [PATCH 1/1] Define dmidecode path at a build stage
|
||||||
|
|
||||||
|
This helps in case then user doesn't have dmidecode in his PATH.
|
||||||
|
For example, if user elevates his privileges with sudo, then he
|
||||||
|
may not inherit some superuser's environmental variables ($PATH,
|
||||||
|
contaning additional directories - /sbin, /usr/sbin and similar).
|
||||||
|
|
||||||
|
In case of failure to determine full path to dmidecode it just
|
||||||
|
fallbacks to the default value.
|
||||||
|
|
||||||
|
Tested only on Linux.
|
||||||
|
|
||||||
|
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
|
||||||
|
---
|
||||||
|
Makefile | 5 ++++-
|
||||||
|
dmi.c | 2 +-
|
||||||
|
2 files changed, 5 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/Makefile b/Makefile
|
||||||
|
index e83fc0b..7919e10 100644
|
||||||
|
--- a/Makefile
|
||||||
|
+++ b/Makefile
|
||||||
|
@@ -169,6 +169,9 @@ CONFIG_DEDIPROG ?= no
|
||||||
|
# Disable wiki printing by default. It is only useful if you have wiki access.
|
||||||
|
CONFIG_PRINT_WIKI ?= no
|
||||||
|
|
||||||
|
+# Try to detect full path for dmidecode
|
||||||
|
+CONFIG_DMIDECODE_PATH ?= $(shell LC_ALL=C type -p dmidecode 2>/dev/null || echo "dmidecode")
|
||||||
|
+
|
||||||
|
ifeq ($(CONFIG_INTERNAL), yes)
|
||||||
|
FEATURE_CFLAGS += -D'CONFIG_INTERNAL=1'
|
||||||
|
PROGRAMMER_OBJS += processor_enable.o chipset_enable.o board_enable.o cbtable.o dmi.o internal.o
|
||||||
|
@@ -323,7 +326,7 @@ $(PROGRAM)$(EXEC_SUFFIX): $(OBJS)
|
||||||
|
TAROPTIONS = $(shell LC_ALL=C tar --version|grep -q GNU && echo "--owner=root --group=root")
|
||||||
|
|
||||||
|
%.o: %.c .features
|
||||||
|
- $(CC) -MMD $(CFLAGS) $(CPPFLAGS) $(FEATURE_CFLAGS) $(SVNDEF) -o $@ -c $<
|
||||||
|
+ $(CC) -MMD $(CFLAGS) $(CPPFLAGS) $(FEATURE_CFLAGS) $(SVNDEF) -DCONFIG_DMIDECODE_PATH=\"$(CONFIG_DMIDECODE_PATH)\" -o $@ -c $<
|
||||||
|
|
||||||
|
# Make sure to add all names of generated binaries here.
|
||||||
|
# This includes all frontends and libflashrom.
|
||||||
|
diff --git a/dmi.c b/dmi.c
|
||||||
|
index f18907f..d483acb 100644
|
||||||
|
--- a/dmi.c
|
||||||
|
+++ b/dmi.c
|
||||||
|
@@ -55,7 +55,7 @@ static const char *dmidecode_names[] = {
|
||||||
|
};
|
||||||
|
|
||||||
|
#define DMI_COMMAND_LEN_MAX 260
|
||||||
|
-static const char *dmidecode_command = "dmidecode";
|
||||||
|
+static const char *dmidecode_command = CONFIG_DMIDECODE_PATH;
|
||||||
|
|
||||||
|
static char *dmistrings[ARRAY_SIZE(dmidecode_names)];
|
||||||
|
|
||||||
|
--
|
||||||
|
1.7.2.3
|
||||||
|
|
16898
flashrom-r1002-r1158.diff
Normal file
16898
flashrom-r1002-r1158.diff
Normal file
File diff suppressed because it is too large
Load Diff
11
flashrom-svn_ver.diff
Normal file
11
flashrom-svn_ver.diff
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
--- Makefile~ 2010-09-12 18:42:42.750110259 +0400
|
||||||
|
+++ Makefile 2010-09-12 18:57:47.557609365 +0400
|
||||||
|
@@ -97,7 +97,7 @@
|
||||||
|
# of the checked out flashrom files.
|
||||||
|
# Note to packagers: Any tree exported with "make export" or "make tarball"
|
||||||
|
# will not require subversion. The downloadable snapshots are already exported.
|
||||||
|
-SVNVERSION := 1001
|
||||||
|
+SVNVERSION := 1158
|
||||||
|
|
||||||
|
RELEASE := 0.9.2
|
||||||
|
VERSION := $(RELEASE)-r$(SVNVERSION)
|
@ -1,17 +1,20 @@
|
|||||||
%global svnrev 1001
|
%global svnrev 1158
|
||||||
|
|
||||||
Summary: Simple program for reading/writing BIOS chips content
|
Summary: Simple program for reading/writing BIOS chips content
|
||||||
Name: flashrom
|
Name: flashrom
|
||||||
Version: 0.9.2
|
Version: 0.9.2
|
||||||
Release: 2%{?dist}
|
Release: 3.svn1158%{?dist}
|
||||||
License: GPLv2
|
License: GPLv2
|
||||||
Group: Applications/System
|
Group: Applications/System
|
||||||
URL: http://flashrom.org
|
URL: http://flashrom.org
|
||||||
Source0: http://qa.coreboot.org/releases/%{name}-%{version}.tar.bz2
|
Source0: http://qa.coreboot.org/releases/%{name}-%{version}.tar.bz2
|
||||||
Source1: http://qa.coreboot.org/releases/%{name}-%{version}.tar.bz2.asc
|
Source1: http://qa.coreboot.org/releases/%{name}-%{version}.tar.bz2.asc
|
||||||
#Patch0: flashrom-r710-r%{svnrev}.diff
|
Patch0: flashrom-r1002-r%{svnrev}.diff
|
||||||
|
Patch1: flashrom-svn_ver.diff
|
||||||
|
Patch2: flashrom-0001-Define-dmidecode-path-at-a-build-stage.patch
|
||||||
BuildRequires: pciutils-devel
|
BuildRequires: pciutils-devel
|
||||||
BuildRequires: zlib-devel
|
BuildRequires: zlib-devel
|
||||||
|
BuildRequires: dmidecode
|
||||||
Requires: dmidecode
|
Requires: dmidecode
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||||
|
|
||||||
@ -24,17 +27,19 @@ and write new contents on the chips ("flash the chip").
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
#%patch0 -p1
|
%patch0 -p1
|
||||||
|
%patch1 -p0
|
||||||
|
%patch2 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
CFLAGS="%{optflags}" %{__make} %{?_smp_mflags}
|
CFLAGS="%{optflags}" make %{?_smp_mflags}
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%{__rm} -rf $RPM_BUILD_ROOT
|
rm -rf $RPM_BUILD_ROOT
|
||||||
%{__make} install DESTDIR=$RPM_BUILD_ROOT PREFIX=%{_prefix}
|
make install DESTDIR=$RPM_BUILD_ROOT PREFIX=%{_prefix}
|
||||||
|
|
||||||
%clean
|
%clean
|
||||||
%{__rm} -rf $RPM_BUILD_ROOT
|
rm -rf $RPM_BUILD_ROOT
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%defattr(-,root,root,-)
|
%defattr(-,root,root,-)
|
||||||
@ -43,6 +48,11 @@ CFLAGS="%{optflags}" %{__make} %{?_smp_mflags}
|
|||||||
%{_mandir}/man8/%{name}.*
|
%{_mandir}/man8/%{name}.*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sun Sep 12 2010 Peter Lemenkov <lemenkov@gmail.com> 0.9.2-3.svn1158
|
||||||
|
- Clean up spec-file
|
||||||
|
- Updated to latest svn ver. 1158
|
||||||
|
- Doubles the number of known boards!
|
||||||
|
|
||||||
* Sun Jun 13 2010 Peter Lemenkov <lemenkov@gmail.com> 0.9.2-2
|
* Sun Jun 13 2010 Peter Lemenkov <lemenkov@gmail.com> 0.9.2-2
|
||||||
- Added missing Requires - dmidecode (for accurate board matching)
|
- Added missing Requires - dmidecode (for accurate board matching)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user