1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61
|
# AAP receipe for Ked Password Manager
# (C) Copyright 2004 Andrey Lebdedev <andrey@micro.lt>
#
# 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; either version 2 of the License, or
# (at your option) any later version.
#
# 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.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
# $Id: main.aap,v 1.2 2004/03/01 22:35:20 kedder Exp $
:tree kedpm {filename = .*\.py}
_recipe.PYTHON_SOURCE += $name
POT = po/messages.pot
GLADE_STRINGS = glade/glade-msg.c
TRANSLATIONS = `glob('po/*.po')`
MOFILES = `sufreplace(".po", "/LC_MESSAGES/kedpm.mo", TRANSLATIONS)`
MODIRS = `sufreplace(".po", "/LC_MESSAGES", TRANSLATIONS)`
all: $POT $MODIRS $MOFILES
#$MOFILES: $TRANSLATIONS
$MODIRS:
:mkdir {r} $target
$TRANSLATIONS: $POT
$POT: $PYTHON_SOURCE $GLADE_STRINGS
:system pygettext -o $target $PYTHON_SOURCE
:system xgettext -a -j -o $target $GLADE_STRINGS
#translations: $Translations
:filetype
suffix po pofile
suffix mo mofile
suffix pot potemplate
:action compile_po mofile pofile
:system msgfmt $source -o $target
:action update_po pofile potemplate
:system msgmerge --update $target $source
:rule po/%/LC_MESSAGES/kedpm.mo : po/%.po
:do compile_po {target=$target} $source
:rule po/%.po : $POT
:do update_po {target=$target} $source
|