aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile17
-rw-r--r--numlock.spec30
-rwxr-xr-xnumlock.xinit4
3 files changed, 24 insertions, 27 deletions
diff --git a/Makefile b/Makefile
index 8fe18c6..42f73d5 100644
--- a/Makefile
+++ b/Makefile
@@ -1,15 +1,10 @@
NAME= numlock
VERSION = $(shell awk '/define version/ { print $$3 }' $(NAME).spec)
-LIB_NAME = lib
-ifneq (,$(shell uname -m | grep "\(x86_64\|sparc64\|ppc64\|s390x\)"))
-LIB_NAME = lib64
-endif
-
TOP=
CFLAGS=-g -O2 -Wall
CC=gcc
-FLAGS=-lX11 -lXtst -I/usr/X11R6/include -L/usr/X11R6/$(LIB_NAME)
+FLAGS=-lX11 -lXtst
enable_X11_numlock: enable_X11_numlock.c
$(CC) $(CFLAGS) $(FLAGS) -o $@ $<
@@ -20,16 +15,16 @@ clean:
rm -f enable_X11_numlock core *.o
install: all
- install -d $(TOP)/usr/X11R6/{bin,man/man1}/
+ install -d $(TOP)/usr/{bin,share/man/man1}/
install -d $(TOP)/etc/profile.d
install -d $(TOP)/$(INITRDDIR)
install -d $(TOP)/etc/X11/xinit.d
- install -m755 enable_X11_numlock $(TOP)/usr/X11R6/bin
- install -m755 man/C/enable_X11_numlock.1 $(TOP)/usr/X11R6/man/man1/
+ install -m755 enable_X11_numlock $(TOP)/usr/bin
+ install -m755 man/C/enable_X11_numlock.1 $(TOP)/usr/share/man/man1/
for i in man/??* ; do \
- install -d $(TOP)/usr/X11R6/man/`basename $$i`/man1 ; \
- install -m 644 $$i/*.1 $(TOP)/usr/X11R6/man/`basename $$i`/man1 ; \
+ install -d $(TOP)/usr/share/man/`basename $$i`/man1 ; \
+ install -m 644 $$i/*.1 $(TOP)/usr/share/man/`basename $$i`/man1 ; \
done
install -m755 numlock.init $(TOP)/$(INITRDDIR)/$(NAME)
diff --git a/numlock.spec b/numlock.spec
index 2e11a3f..3ffda91 100644
--- a/numlock.spec
+++ b/numlock.spec
@@ -3,7 +3,7 @@
%define name numlock
%define version 2.0
-%define release %mkrel 15
+%define release %mkrel 16
Summary: Numlock key locker
Name: %{name}
@@ -13,7 +13,7 @@ License: GPL
Url: http://cvs.mandriva.com/cgi-bin/cvsweb.cgi/soft/numlock/
Group: System/Configuration/Boot and Init
Source0: %{name}-%{version}.tar.bz2
-BuildRequires: XFree86-devel
+BuildRequires: libx11-devel
BuildRoot: %{_tmppath}/%{name}-buildroot
# do not require X11 libs
autoReq: no
@@ -53,21 +53,23 @@ rm -rf $RPM_BUILD_ROOT
%config(noreplace) %{_initrddir}/%{name}
%config(noreplace) /etc/profile.d/%{name}.sh
%config(noreplace) /etc/X11/xinit.d/numlock
-/usr/X11R6/bin/*
-/usr/X11R6/man/man1/*
-/usr/X11R6/man/cs/man1/*
-/usr/X11R6/man/nl/man1/*
-%lang(cs) /usr/X11R6/man/cs/man1/*
-%lang(et) /usr/X11R6/man/et/man1/*
-%lang(eu) /usr/X11R6/man/eu/man1/*
-%lang(fi) /usr/X11R6/man/fi/man1/*
-%lang(fr) /usr/X11R6/man/fr/man1/*
-%lang(it) /usr/X11R6/man/it/man1/*
-%lang(ru) /usr/X11R6/man/ru/man1/*
-%lang(uk) /usr/X11R6/man/uk/man1/*
+/usr/bin/*
+%{_mandir}/man1/*
+%lang(cs) %{_mandir}/cs/man1/*
+%lang(et) %{_mandir}/et/man1/*
+%lang(eu) %{_mandir}/eu/man1/*
+%lang(fi) %{_mandir}/fi/man1/*
+%lang(fr) %{_mandir}/fr/man1/*
+%lang(it) %{_mandir}/it/man1/*
+%lang(nl) %{_mandir}/nl/man1/*
+%lang(ru) %{_mandir}/ru/man1/*
+%lang(uk) %{_mandir}/uk/man1/*
%changelog
+* Tue Aug 22 2006 Pixel <pixel@mandriva.com> 2.0-16mdv2007.0
+- move out of /usr/X11R6
+
* Wed Mar 8 2006 Olivier Blin <oblin@mandriva.com> 2.0-15mdk
- disable autoReq back (not to require X11 libs)
diff --git a/numlock.xinit b/numlock.xinit
index 9d759c8..0cf1ed4 100755
--- a/numlock.xinit
+++ b/numlock.xinit
@@ -8,8 +8,8 @@
# Created On : Wed Apr 12 08:39:24 2000
#---------------------------------------------------------------
-if [ -f /var/lock/subsys/numlock -a -x /usr/X11R6/bin/enable_X11_numlock ]; then
- /usr/X11R6/bin/enable_X11_numlock
+if [ -f /var/lock/subsys/numlock -a -x /usr/bin/enable_X11_numlock ]; then
+ /usr/bin/enable_X11_numlock
fi
# numlock ends here