telephony/libs/rem/Makefile
Kuan-Yi Li 87275752df treewide: replace AUTORELEASE with real PKG_RELEASE
Based on Paul Fertser <fercerpav@gmail.com>'s guidance:
Change AUTORELEASE in rules.mk to:
```
AUTORELEASE = $(if $(DUMP),0,$(shell sed -i "s/\$$(AUTORELEASE)/$(call commitcount,1)/" $(CURDIR)/Makefile))
```

then update all affected packages by:
```
for i in $(git grep -l PKG_RELEASE:=.*AUTORELEASE | sed 's^.*/\([^/]*\)/Makefile^\1^';);
do
	make package/$i/clean
done
```

Signed-off-by: Kuan-Yi Li <kyli@abysm.org>
2023-07-19 04:41:35 +08:00

61 lines
1.6 KiB
Makefile

#
# Copyright (C) 2010-2017 OpenWrt.org
# Copyright (C) 2010 Alfred E. Heggestad
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=rem
PKG_VERSION:=1.0.0
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/baresip/rem/tar.gz/v$(PKG_VERSION)?
PKG_HASH:=bcc91bb521fae183357fb422b00a3981477a22e99d3afe165c4ec50a6bbed9da
PKG_LICENSE:=BSD-3-Clause
PKG_LICENSE_FILES:=docs/COPYING
PKG_MAINTAINER:=Jiri Slachta <jiri@slachta.eu>
PKG_BUILD_PARALLEL:=1
PKG_INSTALL:=1
include $(INCLUDE_DIR)/package.mk
define Package/librem
SUBMENU:=Telephony
SECTION:=libs
CATEGORY:=Libraries
DEPENDS:=+libre
TITLE:=Audio and video processing media library
URL:=https://github.com/baresip/rem
endef
MAKE_FLAGS+= \
CROSS_COMPILE="$(TARGET_CROSS)" \
EXTRA_LFLAGS="$(TARGET_LDFLAGS)" \
LD="$(TARGET_CC)" \
LIBRE_MK="$(STAGING_DIR)/usr/share/re/re.mk" \
LIBRE_INC="$(STAGING_DIR)/usr/include/re" \
LIBRE_SO="$(STAGING_DIR)/usr/lib" \
OS=linux \
RELEASE=1 \
SYSROOT="$(shell $(FIND) $(TOOLCHAIN_DIR) -path '*/include/pthread.h' | sed -ne '1s|/include/pthread.h||p')" \
SYSROOT_ALT="$(STAGING_DIR)/usr"
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include
$(CP) $(PKG_INSTALL_DIR)/usr/include/rem $(1)/usr/include
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/librem.{a,so} $(1)/usr/lib
endef
define Package/librem/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/librem.so $(1)/usr/lib
endef
$(eval $(call BuildPackage,librem))