2 # Copyright (C) 2007-2009 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
12 PKG_VERSION
:=r
$(PKG_REV
)
15 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.bz2
16 PKG_SOURCE_URL
:=https
://ssl.bulix.org
/svn
/lcd4linux
/trunk
/
17 PKG_SOURCE_SUBDIR
:=lcd4linux-
$(PKG_VERSION
)
18 PKG_SOURCE_VERSION
:=$(PKG_REV
)
24 include $(INCLUDE_DIR
)/package.mk
26 define Package
/lcd4linux
30 TITLE
:=LCD display utility
31 URL
:=http
://lcd4linux.bulix.org
/
35 define Package
/lcd4linux
/config
37 depends on PACKAGE_lcd4linux
38 source
"$(SOURCE)/Config.in"
42 define Package
/lcd4linux
/description
43 LCD4Linux is a small program that grabs information from the kernel and
44 some subsystems and displays it on an external liquid crystal display.
47 define Package
/lcd4linux
/conffiles
132 LCD4LINUX_CONFIGURE_DRIVERS
:= \
133 $(foreach c
, $(LCD4LINUX_DRIVERS
), \
134 $(if
$(CONFIG_LCD4LINUX_DRV_
$(c
)),$(c
),) \
137 LCD4LINUX_CONFIGURE_PLUGINS
:= \
138 $(foreach c
, $(LCD4LINUX_PLUGINS
), \
139 $(if
$(CONFIG_LCD4LINUX_PLUGIN_
$(c
)),$(c
),) \
142 ifneq ($(CONFIG_LCD4LINUX_DRV_PNG
),)
143 PKG_BUILD_DEPENDS
+= libgd
146 ifneq ($(CONFIG_LCD4LINUX_DRV_PPM
),)
147 PKG_BUILD_DEPENDS
+= libgd
150 ifneq ($(CONFIG_LCD4LINUX_DRV_G15
),)
151 PKG_BUILD_DEPENDS
+= libgd
154 ifneq ($(CONFIG_LCD4LINUX_DRV_LPH7508
),)
155 PKG_BUILD_DEPENDS
+= libgd
158 ifneq ($(CONFIG_LCD4LINUX_DRV_LUIse
),)
159 PKG_BUILD_DEPENDS
+= libgd
162 ifneq ($(CONFIG_LCD4LINUX_DRV_Noritake
),)
163 PKG_BUILD_DEPENDS
+= libgd
166 ifneq ($(CONFIG_LCD4LINUX_DRV_serdisplib
),)
167 PKG_BUILD_DEPENDS
+= libgd
, serdisplib
170 ifneq ($(CONFIG_LCD4LINUX_DRV_st2205
),)
171 PKG_BUILD_DEPENDS
+= libgd
, st2205tool
174 ifneq ($(CONFIG_LCD4LINUX_DRV_T6963
),)
175 PKG_BUILD_DEPENDS
+= libgd
178 ifneq ($(CONFIG_LCD4LINUX_DRV_Curses
),)
179 PKG_BUILD_DEPENDS
+= libncurses
182 ifneq ($(CONFIG_LCD4LINUX_DRV_VNC
),)
183 PKG_BUILD_DEPENDS
+= libvncserver
186 ifneq ($(CONFIG_LCD4LINUX_DRV_X11
),)
187 PKG_BUILD_DEPENDS
+= libgd
, libX11
190 ifneq ($(CONFIG_LCD4LINUX_PLUGIN_gps
),)
191 PKG_BUILD_DEPENDS
+= libnmeap
194 ifneq ($(CONFIG_LCD4LINUX_PLUGIN_iconv
),)
195 PKG_BUILD_DEPENDS
+= libiconv
198 ifneq ($(CONFIG_LCD4LINUX_PLUGIN_mysql
),)
199 PKG_BUILD_DEPENDS
+= libmysqlclient
202 # XXX: lcd4linux needs at least one driver and one plugin, if none are selected, build'em all
203 ifeq ($(strip $(LCD4LINUX_CONFIGURE_DRIVERS
)),)
204 LCD4LINUX_CONFIGURE_DRIVERS
:=all
206 ifeq ($(strip $(LCD4LINUX_CONFIGURE_PLUGINS
)),)
207 LCD4LINUX_CONFIGURE_PLUGINS
:=all
210 ## TODO PYTHON PLUGIN, DEPENDS on ver >= '2.1.0'
213 EXTRA_CFLAGS
+= $(TARGET_CPPFLAGS
) -I
$(STAGING_DIR
)/usr
/lib
/libiconv
/include
214 EXTRA_LDFLAGS
+= $(TARGET_LDFLAGS
) -Wl
,-rpath-link
,$(STAGING_DIR
)/usr
/lib
-L
$(STAGING_DIR
)/usr
/lib
/libiconv
/lib
216 TARGET_CONFIGURE_OPTS
+=\
217 CC
="$(TARGET_CC) $(EXTRA_CFLAGS) $(EXTRA_LDFLAGS)"
223 --with-drivers
="$(strip $(LCD4LINUX_CONFIGURE_DRIVERS))" \
224 --with-plugins
="$(strip $(LCD4LINUX_CONFIGURE_PLUGINS))" \
227 define Package
/lcd4linux
/install
228 $(INSTALL_DIR
) $(1)/usr
/bin
229 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/$(PKG_NAME
) $(1)/usr
/bin
/
230 $(INSTALL_DIR
) $(1)/etc
231 $(INSTALL_CONF
) .
/files
/$(PKG_NAME
).conf
$(1)/etc
/$(PKG_NAME
).conf
232 $(INSTALL_DIR
) $(1)/etc
/init.d
233 $(INSTALL_BIN
) .
/files
/$(PKG_NAME
).init
$(1)/etc
/init.d
/$(PKG_NAME
)
236 $(eval
$(call BuildPackage
,lcd4linux
))