1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter.git synced 2025-02-13 11:51:54 +00:00
openmptcprouter/root/package/modems/Makefile
Ycarus (Yannick Chabanois) f0ec7d2129 Add more modems support
2022-03-25 08:07:57 +01:00

39 lines
896 B
Makefile

#
# Copyright (C) 2019 Teltonika
#
include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/download.mk
PKG_NAME:=modems
PKG_VERSION:=1
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
include $(INCLUDE_DIR)/package.mk
define Package/modems
SECTION:=utils
CATEGORY:=Utilities
TITLE:=3G/4G modem list
endef
define Build/Compile
endef
define Package/modems/install
$(INSTALL_DIR) $(1)/lib/network/wwan/
$(INSTALL_DATA) $(PKG_BUILD_DIR)/data/* $(1)/lib/network/wwan/
#in order to keep the Lede GIT repo free of filenames with colons,
#we name the files xxxx-yyyy
# and rename here after copying to the build directory
shopt -s nullglob ; \
for filevar in $(1)/lib/network/wwan/*-* ; \
do \
FILENAME=$$$$(basename $$$$filevar) ; \
NEWNAME=$$$${FILENAME//-/:} ; \
mv "$(1)/lib/network/wwan/$$$$FILENAME" "$(1)/lib/network/wwan/$$$$NEWNAME" ; \
done
endef
$(eval $(call BuildPackage,modems))