[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemacs-commit] qemacs qe.c configure Makefile
From: |
Charlie Gordon |
Subject: |
[Qemacs-commit] qemacs qe.c configure Makefile |
Date: |
Sat, 21 Dec 2013 16:24:57 +0000 |
CVSROOT: /sources/qemacs
Module name: qemacs
Changes by: Charlie Gordon <chqrlie> 13/12/21 16:24:57
Modified files:
. : qe.c configure Makefile
Log message:
added configure variables for portability (Haiku from Francois Revel)
Added datadir and mandir for systems that use different directory trees
In Haiku we don't have share/ at the usual prefix, and man pages are in
documentation/man/... So we need to pass those to configure.
This patch adds --datadir and --mandir support, the autofools way.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemacs/qe.c?cvsroot=qemacs&r1=1.101&r2=1.102
http://cvs.savannah.gnu.org/viewcvs/qemacs/configure?cvsroot=qemacs&r1=1.21&r2=1.22
http://cvs.savannah.gnu.org/viewcvs/qemacs/Makefile?cvsroot=qemacs&r1=1.55&r2=1.56
Patches:
Index: qe.c
===================================================================
RCS file: /sources/qemacs/qemacs/qe.c,v
retrieving revision 1.101
retrieving revision 1.102
diff -u -b -r1.101 -r1.102
--- qe.c 3 Dec 2013 17:38:16 -0000 1.101
+++ qe.c 21 Dec 2013 16:24:38 -0000 1.102
@@ -7534,9 +7534,10 @@
}
pstrcat(qs->res_path, sizeof(qs->res_path),
- CONFIG_QE_PREFIX "/share/qe:"
- CONFIG_QE_PREFIX "/lib/qe:"
- "/usr/share/qe:"
+ CONFIG_QE_DATADIR ":"
+ CONFIG_QE_PREFIX "/share/qe" ":"
+ CONFIG_QE_PREFIX "/lib/qe" ":"
+ "/usr/share/qe" ":"
"/usr/lib/qe");
}
Index: configure
===================================================================
RCS file: /sources/qemacs/qemacs/configure,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -b -r1.21 -r1.22
--- configure 19 Dec 2013 00:13:49 -0000 1.21
+++ configure 21 Dec 2013 16:24:56 -0000 1.22
@@ -23,6 +23,8 @@
# default parameters
prefix="/usr/local"
+datadir="${prefix}/share"
+mandir="${prefix}/man"
cross_prefix=""
cc="gcc"
host_cc="gcc"
@@ -223,6 +225,12 @@
--prefix=*)
prefix=`echo $opt | cut -d '=' -f 2`
;;
+ --datadir=*)
+ datadir=`echo $opt | cut -d '=' -f 2`
+ ;;
+ --mandir=*)
+ mandir=`echo $opt | cut -d '=' -f 2`
+ ;;
--source-path=*)
source_path=`echo $opt | cut -d '=' -f 2`
;;
@@ -453,6 +461,8 @@
fi
echo "Install prefix $prefix"
+echo "Shared data dir $datadir"
+echo "Manpages dir $mandir"
echo "Source path $source_path"
echo "C compiler $cc"
echo "Tiny build $tiny"
@@ -477,6 +487,10 @@
echo "prefix=$prefix" >> $TMPMAK
echo "#define CONFIG_QE_PREFIX \"$prefix\"" >> $TMPH
+echo "datadir=$datadir" >> $TMPMAK
+echo "#define CONFIG_QE_DATADIR \"$datadir\"" >> $TMPH
+echo "mandir=$mandir" >> $TMPMAK
+echo "#define CONFIG_QE_MANDIR \"$mandir\"" >> $TMPH
echo "MAKE=$make" >> $TMPMAK
echo "CC=$cc" >> $TMPMAK
echo "GCC_MAJOR=$gcc_major" >> $TMPMAK
Index: Makefile
===================================================================
RCS file: /sources/qemacs/qemacs/Makefile,v
retrieving revision 1.55
retrieving revision 1.56
diff -u -b -r1.55 -r1.56
--- Makefile 17 Dec 2013 23:13:47 -0000 1.55
+++ Makefile 21 Dec 2013 16:24:57 -0000 1.56
@@ -266,7 +266,7 @@
Hebrew.kmap HebrewIsraeli.kmap HebrewP.kmap Israeli.kmap Yiddish.kmap \
Kana.kmap
# Hangul.kmap Hangul2.kmap Hangul3.kmap Unicode2.kmap
-#KMAPS_DIR=$(prefix)/share/yudit/data
+#KMAPS_DIR=$(datadir)/yudit/data
KMAPS_DIR=kmap
KMAPS:=$(addprefix $(KMAPS_DIR)/, $(KMAPS))
@@ -366,15 +366,15 @@
install: $(TARGETS) qe.1
$(INSTALL) -m 755 -d $(DESTDIR)$(prefix)/bin
- $(INSTALL) -m 755 -d $(DESTDIR)$(prefix)/man/man1
- $(INSTALL) -m 755 -d $(DESTDIR)$(prefix)/share/qe
+ $(INSTALL) -m 755 -d $(DESTDIR)$(mandir)/man1
+ $(INSTALL) -m 755 -d $(DESTDIR)$(datadir)/qe
$(INSTALL) -m 755 -s qe$(EXE) $(DESTDIR)$(prefix)/bin/qemacs$(EXE)
ln -sf qemacs $(DESTDIR)$(prefix)/bin/qe$(EXE)
ifdef CONFIG_FFMPEG
ln -sf qemacs$(EXE) $(DESTDIR)$(prefix)/bin/ffplay$(EXE)
endif
- $(INSTALL) -m 644 kmaps ligatures $(DESTDIR)$(prefix)/share/qe
- $(INSTALL) -m 644 qe.1 $(DESTDIR)$(prefix)/man/man1
+ $(INSTALL) -m 644 kmaps ligatures $(DESTDIR)$(datadir)/qe
+ $(INSTALL) -m 644 qe.1 $(DESTDIR)$(mandir)/man1
ifdef CONFIG_HTML
$(INSTALL) -m 755 -s html2png$(EXE) $(DESTDIR)$(prefix)/bin
endif
@@ -383,9 +383,9 @@
rm -f $(DESTDIR)$(prefix)/bin/qemacs$(EXE) \
$(DESTDIR)$(prefix)/bin/qe$(EXE) \
$(DESTDIR)$(prefix)/bin/ffplay$(EXE) \
- $(DESTDIR)$(prefix)/man/man1/qe.1 \
- $(DESTDIR)$(prefix)/share/qe/kmaps \
- $(DESTDIR)$(prefix)/share/qe/ligatures \
+ $(DESTDIR)$(mandir)/man1/qe.1 \
+ $(DESTDIR)$(datadir)/qe/kmaps \
+ $(DESTDIR)$(datadir)/qe/ligatures \
$(DESTDIR)$(prefix)/bin/html2png$(EXE)
rebuild:
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Qemacs-commit] qemacs qe.c configure Makefile,
Charlie Gordon <=