/python/engine/PinYin/Makefile.am
Makefile | 100 lines | 61 code | 9 blank | 30 comment | 2 complexity | e3ee2b7c8329aca41c1fbd561911f867 MD5 | raw file
- # vim:set noet ts=4:
- #
- # scim-python
- #
- # Copyright (c) 2007-2008 Huang Peng <shawn.p.huang@gmail.com>
- #
- #
- # This library is free software; you can redistribute it and/or
- # modify it under the terms of the GNU Lesser General Public
- # License as published by the Free Software Foundation; either
- # version 2 of the License, or (at your option) any later version.
- #
- # This library 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 Lesser General Public License for more details.
- #
- # You should have received a copy of the GNU Lesser 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: $
- #
- if ENABLE_PINYIN
- pinyin_PYTHON = \
- PinYin.py \
- PYUtil.py \
- PYParser.py \
- PYSQLiteDB.py \
- PYCreatePinYinDB.py \
- SpecialTable.py \
- SpecialPhrase.py \
- ZhengJu.py \
- ShuangPin.py \
- JianPin.py \
- QuanPin.py \
- PYDict.py\
- ZhengJuDB.py \
- __init__.py \
- $(NULL)
- pinyindir = $(pkgdatadir)/engine/PinYin
- # PYDATA_FILES = \
- # utf8py.org \
- # utf8pyPhrase.org \
- # CharFreq-Modern_utf8.txt \
- # SogouLabDic-utf8.dic \
- # $(NULL)
- PYDATA_FILES = \
- $(NULL)
- pydb_DATA = py.db
- pydbdir = $(pkgdatadir)/engine/PinYin
- DBVER = 0.1.10.5
- DBTAR = pinyin-database-${DBVER}.tar.bz2
- ${DBTAR}:
- wget http://scim-python.googlecode.com/files/${DBTAR}
- py.db: ${DBTAR}
- tar jxvfm ${DBTAR}
- pyspecial_DATA = special_phrase special_table
- pyspecialdir = $(pkgdatadir)/engine/PinYin
- if ENABLE_DEBIAN_DPKG
- EXTRA_DIST = \
- $(PYDATA_FILES) \
- special_table \
- special_phrase \
- ${DBTAR} \
- $(NULL)
- DISTCLEANFILES = \
- py.db \
- *.pyc \
- $(NULL)
- else
- EXTRA_DIST = \
- $(PYDATA_FILES) \
- special_table \
- special_phrase \
- $(NULL)
- DISTCLEANFILES = \
- py.db \
- *.pyc \
- ${DBTAR} \
- $(NULL)
- endif
- install-data-hook:
- @(if test "${NO_INDEX}" = ""; then \
- cd $(DESTDIR)$(pinyindir); \
- echo "Creating INDEX"; \
- $(PYTHON) -c "import PYSQLiteDB; db = PYSQLiteDB.PYSQLiteDB (filename='py.db'); db.create_indexes ();" ;\
- fi)
- endif
- uninstall-hook: