mirror of
https://gitlab.com/davical-project/davical.git
synced 2026-01-27 00:33:34 +00:00
separate rebuild-translations and building locale/
'make' (or 'make all', if one is interested in the apidoc) should now do everything needed to run from a git checkout. At the same time, it no longer rebuilds all translations (xgettext run etc.). This can be done with 'make translations'.
This commit is contained in:
parent
b1ae485973
commit
93ea4e47f6
2
.gitignore
vendored
2
.gitignore
vendored
@ -9,7 +9,7 @@ rscds.bfproject
|
||||
davical.bfproject
|
||||
locale
|
||||
built-docs
|
||||
built-po
|
||||
built-locale
|
||||
.settings
|
||||
*~
|
||||
testing/dumps
|
||||
|
||||
25
Makefile
25
Makefile
@ -11,18 +11,22 @@ snapshot : version = $(majorversion)-git$(gitrev)
|
||||
snapshot : issnapshot = 1
|
||||
|
||||
.PHONY: nodocs
|
||||
nodocs: htdocs/always.php built-po
|
||||
nodocs: htdocs/always.php built-locale
|
||||
|
||||
.PHONY: all
|
||||
all: htdocs/always.php built-docs built-po
|
||||
all: htdocs/always.php built-docs built-locale
|
||||
|
||||
built-docs: docs/phpdoc.ini htdocs/*.php inc/*.php docs/translation.rst
|
||||
apigen generate --title=DAViCal --todo --tree --deprecated -s inc -s htdocs -d docs/api || phpdoc -c docs/phpdoc.ini || echo "NOTICE: Failed to build API docs"
|
||||
apigen generate --quiet --title=DAViCal --todo --tree --deprecated -s inc -s htdocs -d docs/api || phpdoc -c docs/phpdoc.ini || echo "NOTICE: Failed to build API docs"
|
||||
rst2pdf docs/translation.rst || echo "NOTICE: Failed to build ReST docs"
|
||||
touch $@
|
||||
|
||||
built-po: htdocs/always.php scripts/po/rebuild-translations.sh po/*.po
|
||||
scripts/po/rebuild-translations.sh
|
||||
built-locale: po/*.po
|
||||
for LOCALE in `ls po/*.po | cut -f2 -d/ | cut -f1 -d.` ; do \
|
||||
[ "$${LOCALE}" = "en" ] && continue; \
|
||||
mkdir -p locale/$${LOCALE}/LC_MESSAGES; \
|
||||
msgfmt po/$${LOCALE}.po -o locale/$${LOCALE}/LC_MESSAGES/davical.mo; \
|
||||
done
|
||||
touch $@
|
||||
|
||||
#
|
||||
@ -31,6 +35,13 @@ built-po: htdocs/always.php scripts/po/rebuild-translations.sh po/*.po
|
||||
htdocs/always.php: inc/always.php.in scripts/build-always.sh VERSION dba/davical.sql
|
||||
scripts/build-always.sh <$< >$@
|
||||
|
||||
#
|
||||
# recreate translations
|
||||
#
|
||||
.PHONY: translations
|
||||
translations:
|
||||
scripts/po/rebuild-translations.sh
|
||||
|
||||
#
|
||||
# Build a release .tar.gz file in the directory above us
|
||||
#
|
||||
@ -67,8 +78,8 @@ test:
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -f built-docs built-po
|
||||
rm -rf docs/api
|
||||
rm -f built-docs built-locale
|
||||
rm -rf docs/api locale
|
||||
-find . -name "*~" -delete
|
||||
rm -f docs/translation.pdf
|
||||
rm -f davical.spec
|
||||
|
||||
3
debian/rules
vendored
3
debian/rules
vendored
@ -10,8 +10,7 @@ get-orig-source:
|
||||
dh $@
|
||||
|
||||
override_dh_auto_build:
|
||||
@echo "NOTE: not calling make, do this before building the package and review / commit the result"
|
||||
make built-docs
|
||||
make all
|
||||
|
||||
override_dh_installchangelogs:
|
||||
dh_installchangelogs ChangeLog
|
||||
|
||||
@ -8,8 +8,6 @@
|
||||
[ -n "${DEBUG}" ] && set -o xtrace
|
||||
|
||||
PODIR="po"
|
||||
LOCALEDIR="locale"
|
||||
APPLICATION="davical"
|
||||
|
||||
awldirs="../awl
|
||||
`find .. -type d -name 'awl-*.*'`
|
||||
@ -69,9 +67,3 @@ for LOCALE in `locale_list` ; do
|
||||
msgmerge --no-fuzzy-matching --quiet --width 105 --update ${PODIR}/${LOCALE}.po ${PODIR}/messages.pot
|
||||
done
|
||||
|
||||
for LOCALE in `locale_list` ; do
|
||||
[ "${LOCALE}" = "en" ] && continue
|
||||
mkdir -p ${LOCALEDIR}/${LOCALE}/LC_MESSAGES
|
||||
msgfmt ${PODIR}/${LOCALE}.po -o ${LOCALEDIR}/${LOCALE}/LC_MESSAGES/${APPLICATION}.mo
|
||||
done
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user