aboutsummaryrefslogtreecommitdiff
path: root/deactivated/turris-lcd/Makefile
blob: dbf260aa0db4b4dd60e82206b5339bac130eda04 (plain)
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
#
## Copyright (C) 2016 CZ.NIC z.s.p.o. (http://www.nic.cz/)
#
## This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
# #
#
include $(TOPDIR)/rules.mk

PKG_NAME:=turris-lcd
PKG_VERSION:=1
PKG_RELEASE:=3
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=http://git.cynerd.cz/turris-lcd
PKG_SOURCE:=$(PKG_NAME).tar.gz
PKG_SOURCE_VERSION:=eda6326d35e65098e08518a2c6b499709f8ee67e
PKG_SOURCE:=$(PKG_NAME)-$(PKG_SOURCE_VERSION).tar.gz
PKG_SOURCE_SUBDIR:=$(PKG_NAME)
PKG_MAINTAINER:=Karel Koci
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)

include $(INCLUDE_DIR)/package.mk

define Package/turris-lcd
	TITLE:=turris-lcd
	DEPENDS:=+libc +libstdcpp
endef

# Compilation seems to be some what broken with static library so just go around..
define Build/Compile
	cd $(PKG_BUILD_DIR) && ./configure
	$(MAKE_VARS) $(MAKE) -C $(PKG_BUILD_DIR) $(MAKE_FLAGS) Q=
endef
	#cd $(BUILD_DIR)/turris-lcd && arm-openwrt-linux-g++ -Iliblcd liblcd/I2CIO.cpp liblcd/LCD.cpp liblcd/LiquidCrystal_I2C.cpp liblcd/smbus.c src/turris-lcd.cpp -o turris-lcd

define Package/turris-lcd/install
	$(INSTALL_DIR) $(1)/usr/bin/
	$(INSTALL_BIN) $(PKG_BUILD_DIR)/turris-lcd $(1)/usr/bin/turris-lcd
endef

$(eval $(call BuildPackage,turris-lcd))