Root/stardict/Makefile

1#
2# Copyright (C) 2009 Qi Hardware Inc.
3# Author: Xiangfu Liu <xiangfu@sharism.cc>
4#
5# This is free software, licensed under the GNU General Public License v2.
6# See /LICENSE for more information.
7#
8
9include $(TOPDIR)/rules.mk
10
11PKG_NAME:=stardict
12PKG_VERSION:=3.0.1
13
14PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
15PKG_SOURCE_URL:=http://downloads.sourceforge.net/stardict/
16PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
17
18PKG_INSTALL:=1
19
20include $(INCLUDE_DIR)/package.mk
21include $(INCLUDE_DIR)/nls.mk
22
23define Package/stardict/Default
24    MAINTAINER:="Xiangfu Liu" <xiangfu@sharism.cc>
25    SECTION:=utils
26    CATEGORY:=Utilities
27    DEPENDS:=stardict
28    TITLE:=International Dictionary Software
29endef
30
31define Package/stardict/description
32    StarDict is a Cross-Platform and international dictionary Software.
33endef
34
35define Package/stardict
36    $(call Package/stardict/Default)
37    DEPENDS:=$(ICONV_DEPENDS) $(INTL_DEPENDS) +libgconf2 +gtk2 +libstdcpp +libsigcxx
38endef
39
40define Package/stardict-dic-en-en
41    $(call Package/stardict/Default)
42    TITLE+=(dictionary: English <-> English)
43endef
44
45define Package/stardict-dic-en-cn
46    $(call Package/stardict/Default)
47    TITLE+=(dictionary: oxfordjm English <-> Chinese)
48endef
49
50define Package/stardict-dic-en-sp
51    $(call Package/stardict/Default)
52    TITLE+=(dictionary: I2E English <-> Spanish)
53endef
54
55TARGET_LDFLAGS+= -Wl,-rpath-link=$(STAGING_DIR)/usr/lib
56
57CONFIGURE_CMD =./autogen.sh
58CONFIGURE_ARGS += \
59    --disable-dependency-tracking \
60    --disable-libtool-lock \
61    --disable-spell \
62    --disable-gucharmap \
63    --disable-festival \
64    --disable-espeak \
65    --disable-dictdotcn \
66    --disable-advertisement \
67    --disable-qqwry \
68    --disable-updateinfo \
69    --disable-htmlparse \
70    --disable-xdxfparse \
71    --disable-wordnet \
72    --disable-powerwordparse \
73    --disable-wikiparse \
74    --disable-schemas-install \
75    --disable-deprecations \
76    --disable-gnome-support \
77    --enable-nanonote-support
78
79define Package/stardict/install
80    $(INSTALL_DIR) \
81        $(1)/usr/bin \
82        $(1)/usr/share \
83        $(1)/usr/share/pixmaps \
84        $(1)/usr/lib/stardict/plugins
85
86    $(INSTALL_BIN) \
87        $(PKG_INSTALL_DIR)/usr/bin/stardict \
88        $(1)/usr/bin/
89
90    $(INSTALL_DATA) \
91        $(PKG_INSTALL_DIR)/usr/share/pixmaps/stardict.png \
92        $(1)/usr/share/pixmaps/
93
94    $(CP) \
95        $(PKG_INSTALL_DIR)/usr/share/stardict \
96        $(1)/usr/share/
97
98    $(CP) \
99        $(PKG_INSTALL_DIR)/usr/lib/stardict/plugins/* \
100        $(1)/usr/lib/stardict/plugins/
101endef
102
103define Package/stardict-dic-en-en/install
104    $(INSTALL_DIR) \
105        $(1)/usr/share/stardict/dic
106
107    $(TAR) \
108        -C $(1)/usr/share/stardict/dic/ \
109        -jxf \
110        ./files/stardict-english-2.4.2.tar.bz2
111
112    $(CP) ./files/longman.idx.oft \
113        $(1)/usr/share/stardict/dic/stardict-english-2.4.2/
114endef
115
116define Package/stardict-dic-en-cn/install
117    $(INSTALL_DIR) \
118        $(1)/usr/share/stardict/dic
119
120    $(TAR) \
121        -C $(1)/usr/share/stardict/dic/ \
122        -jxf \
123        ./files/stardict-oxfordjm-ec-2.4.2.tar.bz2
124
125    $(CP) ./files/oxfordjm-ec.idx.oft \
126        $(1)/usr/share/stardict/dic/stardict-oxfordjm-ec-2.4.2/
127endef
128
129define Package/stardict-dic-en-sp/install
130    $(INSTALL_DIR) \
131        $(1)/usr/share/stardict/dic
132
133    $(TAR) \
134        -C $(1)/usr/share/stardict/dic/ \
135        -jxf \
136        ./files/stardict-i2e-2.4.2.tar.bz2
137
138    $(CP) ./files/i2e.idx.oft \
139        $(1)/usr/share/stardict/dic/stardict-i2e-2.4.2/
140endef
141
142$(eval $(call BuildPackage,stardict))
143$(eval $(call BuildPackage,stardict-dic-en-en))
144$(eval $(call BuildPackage,stardict-dic-en-cn))
145$(eval $(call BuildPackage,stardict-dic-en-sp))
146

Archive Download this file



interactive