we can now install Gajim with 'make install'
Gajim is launched throught a bash script that check if we are not root
This commit is contained in:
parent
7e09906db3
commit
1158b206bc
29
Makefile
29
Makefile
|
@ -1,13 +1,38 @@
|
|||
MODULES = common plugins/gtkgui
|
||||
PREFIX = /usr
|
||||
|
||||
FIND= find -regex '.*\.\(\(glade\)\|\(py\)\|\(xpm\)\)'
|
||||
FILES=`$(FIND)`
|
||||
DIRS= `$(FIND) -exec dirname {} \; | sort -u`
|
||||
|
||||
SCRIPTS = \
|
||||
scripts/gajim
|
||||
|
||||
all:
|
||||
msgfmt Messages/fr/LC_MESSAGES/gajim.po -o Messages/fr/LC_MESSAGES/gajim.mo
|
||||
for dir in ${MODULES}; do \
|
||||
for dir in $(MODULES); do \
|
||||
(cd $$dir; make all); \
|
||||
done
|
||||
|
||||
clean:
|
||||
find -name *.pyc -exec rm {} \;
|
||||
for dir in ${MODULES}; do \
|
||||
for dir in $(MODULES) ; do \
|
||||
(cd $$dir; make clean); \
|
||||
done
|
||||
|
||||
install:
|
||||
for d in $(DIRS) ; do \
|
||||
if [ ! -d $(PREFIX)/share/gajim/$$d ] ; then \
|
||||
mkdir -p "$(PREFIX)/share/gajim/$$d"; \
|
||||
fi; \
|
||||
done
|
||||
for f in $(FILES) ; do \
|
||||
DST=`dirname "$$f"`; \
|
||||
cp "$$f" "$(PREFIX)/share/gajim/$$DST/"; \
|
||||
done
|
||||
for s in $(SCRIPTS) ; do \
|
||||
BASE=`basename "$$s"`; \
|
||||
F=`cat "$$s" | sed -e 's!PREFIX!$(PREFIX)!g'`; \
|
||||
echo "$$F" > "$(PREFIX)/bin/$$BASE"; \
|
||||
chmod +x "$(PREFIX)/bin/$$BASE"; \
|
||||
done
|
||||
|
|
|
@ -0,0 +1,25 @@
|
|||
#!/bin/sh
|
||||
## gajim
|
||||
##
|
||||
## Gajim Team:
|
||||
## - Yann Le Boulanger <asterix@crans.org>
|
||||
## - Vincent Hanquez <tab@snarc.org>
|
||||
##
|
||||
## Copyright (C) 2003 Gajim Team
|
||||
##
|
||||
## This program is free software; you can redistribute it and/or modify
|
||||
## it under the terms of the GNU General Public License as published
|
||||
## by the Free Software Foundation; version 2 only.
|
||||
##
|
||||
## This program is distributed in the hope that it will be useful,
|
||||
## but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
## GNU General Public License for more details.
|
||||
|
||||
if [ `id -u` -eq 0 ]; then
|
||||
echo "You must not launch Gajim as root, it is DANGEROUS"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
cd PREFIX/share/gajim
|
||||
./runCore.py
|
Loading…
Reference in New Issue