summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsvu <svu>2004-04-15 23:58:28 +0000
committersvu <svu>2004-04-15 23:58:28 +0000
commitc61a7e7404dc50b5d1e5fffc67ec367b58e0125c (patch)
tree6e70432ff0166d045773d25c6347521ab259445e
parentfff688949cf0becaefb35984f6a079cb99430513 (diff)
now, the symlinks allow distributors to use their own names for the rules - though not really recommended, we have to be backward-compatible
-rw-r--r--configure.in9
-rw-r--r--rules/Makefile.am20
-rw-r--r--xkbdesc.spec.in2
3 files changed, 26 insertions, 5 deletions
diff --git a/configure.in b/configure.in
index e67b795..8644c15 100644
--- a/configure.in
+++ b/configure.in
@@ -21,7 +21,13 @@ AC_ARG_WITH( xkb_base,
[ --with-xkb-base=DIR XKB base path (by default it is /usr/X11R6/lib/X11/xkb)],
xkb_base="$withval",
xkb_base="\$(prefix)/X11R6/lib/X11/xkb" )
-
+
+AC_ARG_WITH( xkb_rules_symlink,
+ [ --with-xkb-rules-symlink=NAME create symlink to "old style" rules files (xfree86 or xorg)],
+ xkb_rules_symlink="$withval" )
+
+AM_CONDITIONAL(CREATE_RULES_SYMLINK, test "x$xkb_rules_symlink" != "x")
+
ALL_LINGUAS="af az bg cs da fr hu nl ru sk sq sr sv tr uk zh_CN"
AM_GLIB_GNU_GETTEXT
@@ -30,6 +36,7 @@ AM_GNU_GETTEXT
AC_PROG_INTLTOOL
AC_SUBST(xkb_base)
+AC_SUBST(xkb_rules_symlink)
AC_OUTPUT([ intl/Makefile po/Makefile.in m4/Makefile
Makefile
diff --git a/rules/Makefile.am b/rules/Makefile.am
index 722eb07..9642a10 100644
--- a/rules/Makefile.am
+++ b/rules/Makefile.am
@@ -1,14 +1,28 @@
-rules_DATA = \
+if CREATE_RULES_SYMLINK
+ extra_rules_file = $(xkb_rules_symlink)
+ extra_dir_file = $(extra_rules_file).xml
+ extra_lst_file = $(extra_rules_file).lst
+
+install-data-hook:
+ ln -s base $(DESTDIR)$(rulesdir)/$(extra_rules_file)
+ ln -s base.lst $(DESTDIR)$(rulesdir)/$(extra_lst_file)
+ ln -s base.xml $(DESTDIR)$(rulesdir)/$(extra_dir_file)
+
+endif
+
+rules_files = \
base base-it.lst base.lst \
sgi sgi.lst \
sun sun.lst \
xfree98 xfree98.lst \
xkb.dtd README
+rules_DATA = $(rules_files)
+
xml_in_files = base.xml.in
-xml_DATA = $(xml_in_files:.xml.in=.xml)
+xml_DATA = $(xml_in_files:.xml.in=.xml)
-EXTRA_DIST= $(rules_DATA) $(xml_in_files) xml2lst.pl
+EXTRA_DIST= $(rules_files) $(xml_in_files) xml2lst.pl
rulesdir = $(xkb_base)/rules
xmldir = $(rulesdir)
diff --git a/xkbdesc.spec.in b/xkbdesc.spec.in
index 2b790d8..b841f6f 100644
--- a/xkbdesc.spec.in
+++ b/xkbdesc.spec.in
@@ -42,4 +42,4 @@ rm -rf $RPM_BUILD_DIR/%{name}-%{version}
%defattr(-, root, root)
%doc AUTHORS ChangeLog NEWS README COPYING
-%{_prefix}/X11R6/lib/X11/xkb/rules/*
+%{_prefix}/X11R6/lib/X11/xkb/*