diff --git a/.gitignore b/.gitignore index 063bb57..54741e2 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ /lsw-0.2.tar.gz +/lsw-0.3.tar.gz diff --git a/lsw-0.2-config.patch b/lsw-0.2-config.patch deleted file mode 100644 index 493cee5..0000000 --- a/lsw-0.2-config.patch +++ /dev/null @@ -1,36 +0,0 @@ -diff --git a/Makefile b/Makefile -index 1d2f43d..7a324ef 100644 ---- a/Makefile -+++ b/Makefile -@@ -40,6 +40,7 @@ install: all - @cp -f lsw ${DESTDIR}${PREFIX}/bin - @chmod 755 ${DESTDIR}${PREFIX}/bin/lsw - @echo installing manual page to ${DESTDIR}${MANPREFIX}/man1/lsw.1 -+ @mkdir -p ${DESTDIR}${MANPREFIX}/man1 - @sed "s/VERSION/${VERSION}/g" < lsw.1 > ${DESTDIR}${MANPREFIX}/man1/lsw.1 - @chmod 644 ${DESTDIR}${MANPREFIX}/man1/lsw.1 - -diff --git a/config.mk b/config.mk -index 0383aa9..725d488 100644 ---- a/config.mk -+++ b/config.mk -@@ -2,7 +2,7 @@ - VERSION = 0.2 - - # paths --PREFIX = /usr/local -+PREFIX?= /usr/local - MANPREFIX = ${PREFIX}/share/man - - X11INC = /usr/X11R6/include -@@ -14,8 +14,8 @@ LIBS = -L${X11LIB} -lX11 - - # flags - CPPFLAGS = -DVERSION=\"${VERSION}\" --CFLAGS = -ansi -pedantic -Wall -Os ${INCS} ${CPPFLAGS} --LDFLAGS = -s ${LIBS} -+CFLAGS = ${RPM_OPT_FLAGS} ${INCS} ${CPPFLAGS} -+LDFLAGS = ${LIBS} - - # compiler and linker - CC = cc diff --git a/lsw-0.3-config.patch b/lsw-0.3-config.patch new file mode 100644 index 0000000..1f1fc75 --- /dev/null +++ b/lsw-0.3-config.patch @@ -0,0 +1,24 @@ +diff --git a/config.mk b/config.mk +index 1d32307..3527fee 100644 +--- a/config.mk ++++ b/config.mk +@@ -2,7 +2,7 @@ + VERSION = 0.3 + + # paths +-PREFIX = /usr/local ++PREFIX ?= /usr/local + MANPREFIX = ${PREFIX}/share/man + + X11INC = /usr/X11R6/include +@@ -14,8 +14,8 @@ LIBS = -L${X11LIB} -lX11 + + # flags + CPPFLAGS = -DVERSION=\"${VERSION}\" +-CFLAGS = -ansi -pedantic -Wall -Os ${INCS} ${CPPFLAGS} +-LDFLAGS = -s ${LIBS} ++CFLAGS = ${RPM_OPT_FLAGS} ${INCS} ${CPPFLAGS} ++LDFLAGS += ${LIBS} + + # compiler and linker + CC = cc diff --git a/lsw.spec b/lsw.spec index 59114ac..f263214 100644 --- a/lsw.spec +++ b/lsw.spec @@ -1,12 +1,12 @@ Name: lsw -Version: 0.2 -Release: 7%{?dist} +Version: 0.3 +Release: 1%{?dist} Summary: Prints all window titles of DISPLAY to standard output Group: User Interface/X License: MIT URL: http://tools.suckless.org/%{name} Source0: http://dl.suckless.org/tools/%{name}-%{version}.tar.gz -Patch0: lsw-0.2-config.patch +Patch0: lsw-0.3-config.patch BuildRequires: libX11-devel %description @@ -18,17 +18,22 @@ be useful for script integration. %patch0 -p1 -b .config %build +export LDFLAGS=%{?__global_ldflags} make %{?_smp_mflags} %install make install DESTDIR=%{buildroot} PREFIX=%{_prefix} %files -%doc LICENSE README +%license LICENSE +%doc README %{_bindir}/lsw %{_mandir}/man1/lsw.1* %changelog +* Mon Dec 01 2014 Petr Ĺ abata - 0.3-1 +- 0.3 bump + * Sun Aug 17 2014 Fedora Release Engineering - 0.2-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild diff --git a/sources b/sources index 115898e..6796fa3 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -5ddd61d04ff084a39494b2aa06c00b65 lsw-0.2.tar.gz +3ae42c41a7ceda8ddf6e0fbab0866f79 lsw-0.3.tar.gz