/
Makefile
66 lines (53 loc) · 1.68 KB
/
Makefile
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
#
# Copyright (C) 2019 Sebastian Kemper <sebastian_ml@gmx.net>
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=libks
PKG_VERSION:=2.0.2
PKG_RELEASE:=1
PKG_SOURCE:=libks-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/signalwire/libks/tar.gz/v$(PKG_VERSION)?
PKG_HASH:=af94f9fcdb2022b8f09187309ac2d372a5a4cc639af77cd4375f2d5c88b4fd63
PKG_BUILD_PARALLEL:=1
CMAKE_INSTALL:=1
PKG_LICENSE:= \
BSD-1-Clause \
BSD-3-Clause \
ISC \
MIT \
PUBLICDOMAIN \
twofish
PKG_LICENSE_FILES:=copyright
PKG_MAINTAINER:=Sebastian Kemper <sebastian_ml@gmx.net>
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk
define Package/libks
SUBMENU:=Telephony
SECTION:=libs
CATEGORY:=Libraries
TITLE:=Foundational support for SignalWire C products
URL:=https://github.com/signalwire/libks
ABI_VERSION:=2
DEPENDS:=+libatomic +libopenssl +libuuid
endef
# Otherwise OpenWrt's CPPFLAGS are ignored
TARGET_CFLAGS += $(TARGET_CPPFLAGS)
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include/libks2/libks/cmake
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/libks2/libks/*.h \
$(1)/usr/include/libks2/libks
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/libks2/libks/cmake/* \
$(1)/usr/include/libks2/libks/cmake
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libks2.so* $(1)/usr/lib
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libks2.pc \
$(1)/usr/lib/pkgconfig
endef
define Package/libks/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libks2.so.$(ABI_VERSION)* $(1)/usr/lib
endef
$(eval $(call BuildPackage,libks))