From 603912ee73e56a111dc7463f18bb2e5fff4407a6 Mon Sep 17 00:00:00 2001 From: Jarod Wilson Date: Feb 13 2008 18:36:53 +0000 Subject: Fix build w/gcc 4.3 --- diff --git a/powerman-1.0.32-header-includes.patch b/powerman-1.0.32-header-includes.patch new file mode 100644 index 0000000..9f54f8a --- /dev/null +++ b/powerman-1.0.32-header-includes.patch @@ -0,0 +1,57 @@ +diff -Naurp powerman-1.0.32.orig/src/client.c powerman-1.0.32/src/client.c +--- powerman-1.0.32.orig/src/client.c 2006-04-26 20:17:33.000000000 -0400 ++++ powerman-1.0.32/src/client.c 2008-02-13 13:25:56.000000000 -0500 +@@ -31,6 +31,7 @@ + #include + #include + #include ++#include + + #include + #include +diff -Naurp powerman-1.0.32.orig/src/parse.y powerman-1.0.32/src/parse.y +--- powerman-1.0.32.orig/src/parse.y 2006-11-14 16:29:53.000000000 -0500 ++++ powerman-1.0.32/src/parse.y 2008-02-13 13:29:37.000000000 -0500 +@@ -37,6 +37,7 @@ + #include + #include + #include ++#include + + #include "powerman.h" + #include "list.h" +diff -Naurp powerman-1.0.32.orig/src/powerman.c powerman-1.0.32/src/powerman.c +--- powerman-1.0.32.orig/src/powerman.c 2004-02-20 11:51:06.000000000 -0500 ++++ powerman-1.0.32/src/powerman.c 2008-02-13 13:28:36.000000000 -0500 +@@ -34,6 +34,7 @@ + #include + #include + #include ++#include + + #include "powerman.h" + #include "wrappers.h" +diff -Naurp powerman-1.0.32.orig/src/powermand.c powerman-1.0.32/src/powermand.c +--- powerman-1.0.32.orig/src/powermand.c 2004-02-20 11:51:06.000000000 -0500 ++++ powerman-1.0.32/src/powermand.c 2008-02-13 13:28:47.000000000 -0500 +@@ -35,6 +35,7 @@ + #include + #include + #include ++#include + + #include "powerman.h" + #include "list.h" +diff -Naurp powerman-1.0.32.orig/src/wrappers.c powerman-1.0.32/src/wrappers.c +--- powerman-1.0.32.orig/src/wrappers.c 2005-03-09 06:11:46.000000000 -0500 ++++ powerman-1.0.32/src/wrappers.c 2008-02-13 13:26:48.000000000 -0500 +@@ -38,6 +38,9 @@ + #include + #include + #include ++#include ++#define __USE_GNU /* needed for regex.h */ ++#include + #include + #include + #if HAVE_POLL diff --git a/powerman.spec b/powerman.spec index ba00246..c869156 100644 --- a/powerman.spec +++ b/powerman.spec @@ -1,6 +1,6 @@ Name: powerman Version: 1.0.32 -Release: 4%{?dist} +Release: 5%{?dist} Summary: PowerMan - Power to the Cluster Group: Applications/System @@ -8,6 +8,7 @@ License: GPL Url: http://sourceforge.net/projects/powerman Source0: http://dl.sourceforge.net/sourceforge/%{name}/%{name}-%{version}.tar.bz2 Patch1: powerman-1.0.25-optflags.patch +Patch2: powerman-1.0.32-header-includes.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: flex bison readline-devel @@ -34,6 +35,7 @@ Expect-like configurability simplifies the addition of new devices. %setup -q # Honor $RPM_OPT_FLAGS %patch1 -p1 -b .optflags +%patch2 -p1 -b .headers %if "%{?fedora}" >= "9" sed -i -e 's/termcap/ncurses/g' src/Makefile %endif @@ -89,6 +91,9 @@ fi %{_initrddir}/%{name} %changelog +* Wed Feb 13 2008 Jarod Wilson 1.0.32-5 +- Fix up header includes to build w/gcc 4.3 + * Thu Jan 31 2008 Jarod Wilson 1.0.32-4 - And now make it build with ncurses instead of termcap in f9+