diff options
author | fujiwarat <takao.fujiwara1@gmail.com> | 2016-03-02 19:14:22 +0900 |
---|---|---|
committer | fujiwarat <takao.fujiwara1@gmail.com> | 2016-03-02 19:14:22 +0900 |
commit | 6aa89efa0e3b86af08d479187dba33554c701ec6 (patch) | |
tree | 555ac7cf001146736deb737c5a43b0172a83385d /setup | |
parent | 9fd13449f61481b8b7d7b3572493c43a573675a5 (diff) | |
download | ibus-anthy-6aa89efa0e3b86af08d479187dba33554c701ec6.tar.gz |
Fixed environment variables in anthy.xml and scripts (#4)
Diffstat (limited to 'setup')
-rw-r--r-- | setup/python2/Makefile.am | 29 | ||||
-rw-r--r-- | setup/python2/ibus-setup-anthy.in | 7 | ||||
-rw-r--r-- | setup/python3/Makefile.am | 29 | ||||
-rw-r--r-- | setup/python3/ibus-setup-anthy.in | 7 |
4 files changed, 36 insertions, 36 deletions
diff --git a/setup/python2/Makefile.am b/setup/python2/Makefile.am index f1a8e8d..948f0a8 100644 --- a/setup/python2/Makefile.am +++ b/setup/python2/Makefile.am @@ -4,8 +4,8 @@ # # Copyright (c) 2007-2008 Peng Huang <shawn.p.huang@gmail.com> # Copyright (c) 2009 Hideaki ABE <abe.sendai@gmail.com> -# Copyright (c) 2010-2013 Takao Fujiwara <takao.fujiwara1@gmail.com> -# Copyright (c) 2007-2013 Red Hat, Inc. +# Copyright (c) 2010-2016 Takao Fujiwara <takao.fujiwara1@gmail.com> +# Copyright (c) 2007-2016 Red Hat, Inc. # # 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 @@ -61,13 +61,13 @@ setup_anthydir = $(datadir)/ibus-anthy/setup CONFIG_CLEAN_FILES = \ $(BUILT_SOURCES) \ - $(libexec_SCRIPTS) \ $(NULL) CLEANFILES = \ $(BUILT_SOURCES) \ $(desktop_DATA) \ $(desktop_in_files) \ + $(libexec_SCRIPTS) \ *.pyc \ $(NULL) @@ -76,6 +76,12 @@ EXTRA_DIST = \ $(setup_anthy_built_in_files) \ $(NULL) +ibus-setup-anthy: ibus-setup-anthy.in + sed -e "s|\@prefix\@|$(prefix)|g" \ + -e "s|\@localedir\@|$(localedir)|g" \ + -e "s|\@PYTHON\@|$(PYTHON)|g" \ + $< > $@ + anthyprefs.py: anthyprefs.py.in sed -e "s|\@ANTHY_ZIPCODE_FILE\@|$(ANTHY_ZIPCODE_FILE)|g" \ -e "s|\@KASUMI_EXEC_FILE\@|$(KASUMI_EXEC_FILE)|g" \ @@ -86,16 +92,13 @@ anthyprefs.py: anthyprefs.py.in $< > $@ _config.py: _config.py.in - ( \ - PKGDATADIR=$(pkgdatadir); \ - LIBEXECDIR=$(libexecdir); \ - DATADIR=$(datadir); \ - LAYOUT=$(LAYOUT); \ - SYMBOL_CHAR_INT=$(SYMBOL_CHAR_INT); \ - ICON_PREFERENCE=$(ICON_PREFERENCE); \ - s=`cat $<`; \ - eval "echo \"$${s}\""; \ - ) > $@ + sed -e "s|\@pkgdatadir\@|$(pkgdatadir)|g" \ + -e "s|\@libexecdir\@|$(libexecdir)|g" \ + -e "s|\@datadir\@|$(datadir)|g" \ + -e "s|\@LAYOUT\@|$(LAYOUT)|g" \ + -e "s|\@SYMBOL_CHAR_INT\@|$(SYMBOL_CHAR_INT)|g" \ + -e "s|\@ICON_PREFERENCE\@|$(ICON_PREFERENCE)|g" \ + $< > $@ # Need a time lag between .py and .py.in files to build .py files # because *_PYTHON valuables are installed in the tarball. diff --git a/setup/python2/ibus-setup-anthy.in b/setup/python2/ibus-setup-anthy.in index f8832fd..b936d2c 100644 --- a/setup/python2/ibus-setup-anthy.in +++ b/setup/python2/ibus-setup-anthy.in @@ -4,8 +4,8 @@ # ibus-tmpl - The Input Bus template project # # Copyright (c) 2007-2008 Peng Huang <shawn.p.huang@gmail.com> -# Copyright (c) 2010-2013 Takao Fujiwara <takao.fujiwara1@gmail.com> -# Copyright (c) 2007-2013 Red Hat, Inc. +# Copyright (c) 2010-2016 Takao Fujiwara <takao.fujiwara1@gmail.com> +# Copyright (c) 2007-2016 Red Hat, Inc. # # 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 @@ -21,8 +21,5 @@ # with this program; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -prefix=@prefix@ -datarootdir=@datarootdir@ export IBUS_LOCALEDIR=@localedir@ exec @PYTHON@ @prefix@/share/ibus-anthy/setup/main.py $@ - diff --git a/setup/python3/Makefile.am b/setup/python3/Makefile.am index f1a8e8d..948f0a8 100644 --- a/setup/python3/Makefile.am +++ b/setup/python3/Makefile.am @@ -4,8 +4,8 @@ # # Copyright (c) 2007-2008 Peng Huang <shawn.p.huang@gmail.com> # Copyright (c) 2009 Hideaki ABE <abe.sendai@gmail.com> -# Copyright (c) 2010-2013 Takao Fujiwara <takao.fujiwara1@gmail.com> -# Copyright (c) 2007-2013 Red Hat, Inc. +# Copyright (c) 2010-2016 Takao Fujiwara <takao.fujiwara1@gmail.com> +# Copyright (c) 2007-2016 Red Hat, Inc. # # 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 @@ -61,13 +61,13 @@ setup_anthydir = $(datadir)/ibus-anthy/setup CONFIG_CLEAN_FILES = \ $(BUILT_SOURCES) \ - $(libexec_SCRIPTS) \ $(NULL) CLEANFILES = \ $(BUILT_SOURCES) \ $(desktop_DATA) \ $(desktop_in_files) \ + $(libexec_SCRIPTS) \ *.pyc \ $(NULL) @@ -76,6 +76,12 @@ EXTRA_DIST = \ $(setup_anthy_built_in_files) \ $(NULL) +ibus-setup-anthy: ibus-setup-anthy.in + sed -e "s|\@prefix\@|$(prefix)|g" \ + -e "s|\@localedir\@|$(localedir)|g" \ + -e "s|\@PYTHON\@|$(PYTHON)|g" \ + $< > $@ + anthyprefs.py: anthyprefs.py.in sed -e "s|\@ANTHY_ZIPCODE_FILE\@|$(ANTHY_ZIPCODE_FILE)|g" \ -e "s|\@KASUMI_EXEC_FILE\@|$(KASUMI_EXEC_FILE)|g" \ @@ -86,16 +92,13 @@ anthyprefs.py: anthyprefs.py.in $< > $@ _config.py: _config.py.in - ( \ - PKGDATADIR=$(pkgdatadir); \ - LIBEXECDIR=$(libexecdir); \ - DATADIR=$(datadir); \ - LAYOUT=$(LAYOUT); \ - SYMBOL_CHAR_INT=$(SYMBOL_CHAR_INT); \ - ICON_PREFERENCE=$(ICON_PREFERENCE); \ - s=`cat $<`; \ - eval "echo \"$${s}\""; \ - ) > $@ + sed -e "s|\@pkgdatadir\@|$(pkgdatadir)|g" \ + -e "s|\@libexecdir\@|$(libexecdir)|g" \ + -e "s|\@datadir\@|$(datadir)|g" \ + -e "s|\@LAYOUT\@|$(LAYOUT)|g" \ + -e "s|\@SYMBOL_CHAR_INT\@|$(SYMBOL_CHAR_INT)|g" \ + -e "s|\@ICON_PREFERENCE\@|$(ICON_PREFERENCE)|g" \ + $< > $@ # Need a time lag between .py and .py.in files to build .py files # because *_PYTHON valuables are installed in the tarball. diff --git a/setup/python3/ibus-setup-anthy.in b/setup/python3/ibus-setup-anthy.in index f8832fd..b936d2c 100644 --- a/setup/python3/ibus-setup-anthy.in +++ b/setup/python3/ibus-setup-anthy.in @@ -4,8 +4,8 @@ # ibus-tmpl - The Input Bus template project # # Copyright (c) 2007-2008 Peng Huang <shawn.p.huang@gmail.com> -# Copyright (c) 2010-2013 Takao Fujiwara <takao.fujiwara1@gmail.com> -# Copyright (c) 2007-2013 Red Hat, Inc. +# Copyright (c) 2010-2016 Takao Fujiwara <takao.fujiwara1@gmail.com> +# Copyright (c) 2007-2016 Red Hat, Inc. # # 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 @@ -21,8 +21,5 @@ # with this program; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -prefix=@prefix@ -datarootdir=@datarootdir@ export IBUS_LOCALEDIR=@localedir@ exec @PYTHON@ @prefix@/share/ibus-anthy/setup/main.py $@ - |