Browse Source

Merge pull request #1516 from bk138/ola-0.9.6

ola: Update to 0.9.6, tidy up makefile, try to resolve build dependencies
lilik-openwrt-22.03
Steven Barth 9 years ago
parent
commit
a48f4b0603
2 changed files with 34 additions and 49 deletions
  1. +29
    -43
      net/ola/Makefile
  2. +5
    -6
      net/ola/files/olad.init

+ 29
- 43
net/ola/Makefile View File

@ -1,5 +1,5 @@
# #
# Copyright (C) 2006-2011 OpenWrt.org
# Copyright (C) 2006-2015 OpenWrt.org
# Copyright (C) 2015 Christian Beier <dontmind@freeshell.org> # Copyright (C) 2015 Christian Beier <dontmind@freeshell.org>
# #
# This is free software, licensed under the GNU General Public License v2. # This is free software, licensed under the GNU General Public License v2.
@ -9,13 +9,13 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=ola PKG_NAME:=ola
PKG_VERSION:=0.9.3
PKG_VERSION:=0.9.6
PKG_RELEASE:=1 PKG_RELEASE:=1
PKG_SOURCE_PROTO:=git PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://github.com/OpenLightingProject/ola.git PKG_SOURCE_URL:=https://github.com/OpenLightingProject/ola.git
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_VERSION:=d949ab88ab2c12d4d94b50a0a0df633d634f08fd
PKG_SOURCE_VERSION:=e9ece0540fb40beb1be33417cb7e0abf45af74e0
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_LICENSE:=LGPL-2.1+ PKG_LICENSE:=LGPL-2.1+
@ -25,34 +25,36 @@ PKG_INSTALL:=1
PKG_BUILD_PARALLEL:=1 PKG_BUILD_PARALLEL:=1
PKG_USE_MIPS16:=0 PKG_USE_MIPS16:=0
PKG_BUILD_DEPENDS:=protobuf/host ola/host
HOST_BUILD_DEPENDS:=protobuf/host
PKG_BUILD_DEPENDS:=ola/host
include $(INCLUDE_DIR)/host-build.mk
include $(INCLUDE_DIR)/package.mk include $(INCLUDE_DIR)/package.mk
define Package/ola define Package/ola
SECTION:=net SECTION:=net
CATEGORY:=Network CATEGORY:=Network
TITLE:=Open Lighting Architecture Daemon TITLE:=Open Lighting Architecture Daemon
URL:=https://www.openlighting.org/ URL:=https://www.openlighting.org/
MAINTAINER:=Christian Beier <dontmind@freeshell.org> MAINTAINER:=Christian Beier <dontmind@freeshell.org>
DEPENDS:=+protobuf +libusb-1.0 +libuuid +libstdcpp +libpthread +librt +zlib +libncurses +sudo @BROKEN
DEPENDS:=+protobuf +libusb-1.0 +libuuid +libstdcpp +libpthread +librt +zlib +libncurses +sudo
endef endef
define Package/ola/description define Package/ola/description
OLA (Open Lighting Architecture) is a framework that allows applications to
OLA (Open Lighting Architecture) is a framework that allows applications to
send and receive DMX512, using various hardware devices and 'DMX over IP' send and receive DMX512, using various hardware devices and 'DMX over IP'
protocols. It enables software controllers talk to DMX hardware. protocols. It enables software controllers talk to DMX hardware.
endef endef
CONFIGURE_ARGS += \
--disable-dependency-tracking \
--disable-static \
--disable-fatal-warnings \
--disable-unittests \
--disable-http \
--with-ola-protoc-plugin=$(HOST_BUILD_DIR)/protoc/ola_protoc_plugin
include $(INCLUDE_DIR)/host-build.mk
# When building the host part, disable as much as possible to speed up
# the configure step and avoid missing host dependencies.
# Stolen from http://git.buildroot.net/buildroot/commit/?id=66056a5179ef49f2ec10ba5d7fbd1a58863d1350
define Host/Configure
$(call Host/Configure/Default,\
HOST_CONFIGURE_ARGS += \
--disable-all-plugins \ --disable-all-plugins \
--disable-slp \ --disable-slp \
--disable-osc \ --disable-osc \
@ -63,52 +65,38 @@ define Host/Configure
--disable-examples \ --disable-examples \
--disable-unittests \ --disable-unittests \
--disable-doxygen-html \ --disable-doxygen-html \
--disable-doxygen-doc)
endef
--disable-doxygen-doc
# only build the ola_protoc thingy # only build the ola_protoc thingy
define Host/Compile define Host/Compile
cd $(HOST_BUILD_DIR); \ cd $(HOST_BUILD_DIR); \
$(MAKE) protoc/ola_protoc
$(MAKE) protoc/ola_protoc_plugin
endef endef
# only need ola_protoc
# nothing to install for host part
define Host/Install define Host/Install
$(INSTALL_DIR) $(STAGING_DIR_HOST)/bin
$(CP) $(HOST_BUILD_DIR)/protoc/ola_protoc $(STAGING_DIR_HOST)/bin/
endef
$(eval $(call HostBuild))
define Build/Configure
$(call Build/Configure/Default,\
--disable-dependency-tracking \
--disable-static \
--disable-fatal-warnings \
--disable-unittests \
--disable-http \
--with-ola-protoc=$(STAGING_DIR_HOST)/bin/ola_protoc)
endef endef
define Build/InstallDev define Build/InstallDev
mkdir -p $(1)/usr/include
$(INSTALL_DIR) $(1)/usr/include
$(CP) $(PKG_INSTALL_DIR)/usr/include/ola $(1)/usr/include/ $(CP) $(PKG_INSTALL_DIR)/usr/include/ola $(1)/usr/include/
mkdir -p $(1)/usr/include
$(CP) $(PKG_INSTALL_DIR)/usr/include/olad $(1)/usr/include/ $(CP) $(PKG_INSTALL_DIR)/usr/include/olad $(1)/usr/include/
mkdir -p $(1)/usr/lib
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/ $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/
endef endef
define Package/ola/install define Package/ola/install
$(INSTALL_DIR) $(1)/usr/bin $(INSTALL_DIR) $(1)/usr/bin
$(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin $(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin
$(INSTALL_DIR) $(1)/usr/lib $(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib
$(INSTALL_DIR) $(1)/etc/init.d $(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/olad.init $(1)/etc/init.d/olad $(INSTALL_BIN) ./files/olad.init $(1)/etc/init.d/olad
$(INSTALL_DIR) $(1)/usr/share/ola/pids $(INSTALL_DIR) $(1)/usr/share/ola/pids
$(CP) $(PKG_INSTALL_DIR)/usr/share/ola/pids/* $(1)/usr/share/ola/pids $(CP) $(PKG_INSTALL_DIR)/usr/share/ola/pids/* $(1)/usr/share/ola/pids
endef endef
@ -117,12 +105,10 @@ define Package/ola/postinst
#!/bin/sh #!/bin/sh
# make sure the conf dir exists and is writeable by the group olad uses # make sure the conf dir exists and is writeable by the group olad uses
mkdir -p /etc/ola
chgrp nogroup /etc/ola
chmod 775 $(1)/etc/ola
exit 0
mkdir -p $${IPKG_INSTROOT}/etc/ola
chgrp nogroup $${IPKG_INSTROOT}/etc/ola
chmod 775 $${IPKG_INSTROOT}/etc/ola
endef endef
$(eval $(call HostBuild))
$(eval $(call BuildPackage,ola)) $(eval $(call BuildPackage,ola))

+ 5
- 6
net/ola/files/olad.init View File

@ -1,5 +1,5 @@
#!/bin/sh /etc/rc.common #!/bin/sh /etc/rc.common
# Copyright (C) 2009-2011 OpenWrt.org
# Copyright (C) 2009-2015 OpenWrt.org
# Copyright (C) 2015 Christian Beier <dontmind@freeshell.org> # Copyright (C) 2015 Christian Beier <dontmind@freeshell.org>
USE_PROCD=1 USE_PROCD=1
@ -7,9 +7,8 @@ USE_PROCD=1
START=90 START=90
start_service() { start_service() {
procd_open_instance
procd_set_param command sudo -u nobody /usr/bin/olad --syslog --log-level 3 --config-dir /etc/ola
procd_set_param respawn
procd_close_instance
procd_open_instance
procd_set_param command sudo -u nobody /usr/bin/olad --syslog --log-level 2 --config-dir /etc/ola
procd_set_param respawn
procd_close_instance
} }

Loading…
Cancel
Save