2010-02-01 14:11:53 +00:00
|
|
|
prefix=/usr/local
|
2010-01-31 05:33:54 +00:00
|
|
|
LIBDIR=$(DESTDIR)$(prefix)/lib
|
|
|
|
BINDIR=$(DESTDIR)$(prefix)/bin
|
|
|
|
DATADIR=$(DESTDIR)$(prefix)/share
|
|
|
|
LOCALEDIR=$(DATADIR)/locale
|
|
|
|
MANDIR=$(DATADIR)/man
|
|
|
|
INSTALL=install
|
|
|
|
|
2010-02-15 00:20:47 +00:00
|
|
|
all:
|
2010-01-31 15:09:58 +00:00
|
|
|
cd src/xmpppy-0.5.0rc1 && pwd && python setup.py build && cp -r xmpp ..
|
|
|
|
|
2010-01-31 05:33:54 +00:00
|
|
|
clean: Makefile
|
|
|
|
|
2010-01-31 15:13:41 +00:00
|
|
|
install:all
|
2010-01-31 15:09:58 +00:00
|
|
|
$(INSTALL) -d $(LOCALEDIR) $(BINDIR) $(DATADIR)/poezio $(DATADIR)/poezio/data $(DATADIR)/poezio/src $(DATADIR)/poezio/src/xmpp
|
2010-01-31 05:33:54 +00:00
|
|
|
|
|
|
|
$(INSTALL) -m644 data/* $(DATADIR)/poezio/data/
|
|
|
|
|
|
|
|
for sourcefile in `find src/ -maxdepth 1 -type f | grep -v '.svn' | grep -v '.pyc'` ; do \
|
|
|
|
$(INSTALL) -m644 $$sourcefile $(DATADIR)/poezio/src; \
|
|
|
|
done
|
2010-01-31 15:09:58 +00:00
|
|
|
$(INSTALL) -m644 src/xmpp/* $(DATADIR)/poezio/src/xmpp/
|
2010-01-31 05:33:54 +00:00
|
|
|
|
2010-02-01 20:45:26 +00:00
|
|
|
echo "#!/usr/bin/env sh" > $(BINDIR)/poezio
|
2010-01-31 05:33:54 +00:00
|
|
|
echo "cd $(DATADIR)/poezio/src/ && python client.py" >> $(BINDIR)/poezio
|
2010-01-31 14:23:14 +00:00
|
|
|
chmod 755 $(BINDIR)/poezio
|
2010-01-31 05:33:54 +00:00
|
|
|
|
|
|
|
for localename in `find locale/ -maxdepth 1 -type d | grep -v '.svn' | sed 's:locale/::g'` ; do \
|
|
|
|
if [ -d locale/$$localename ]; then \
|
|
|
|
$(INSTALL) -d $(LOCALEDIR)/$$localename; \
|
|
|
|
$(INSTALL) -d $(LOCALEDIR)/$$localename/LC_MESSAGES; \
|
|
|
|
msgfmt locale/$$localename/LC_MESSAGES/poezio.po -o locale/$$localename/LC_MESSAGES/poezio.mo -v; \
|
|
|
|
$(INSTALL) -m644 locale/$$localename/LC_MESSAGES/poezio.mo $(LOCALEDIR)/$$localename/LC_MESSAGES; \
|
|
|
|
fi \
|
|
|
|
done
|
|
|
|
|
|
|
|
uninstall:
|
|
|
|
rm -f $(BINDIR)/poezio
|
|
|
|
rm -rf $(DATADIR)/poezio
|
|
|
|
|
|
|
|
for gettextfile in `find $(LOCALEDIR) -name 'poezio.mo'` ; do \
|
|
|
|
rm -f $$gettextfile; \
|
|
|
|
done
|
|
|
|
|
|
|
|
pot:
|
|
|
|
xgettext src/*.py --from-code=utf-8 --keyword=_ -o locale/poezio.pot
|