blob: 6a420d59b95b300f078e66feaada749a5f6f9305 [file] [log] [blame]
b.liud440f9f2025-04-18 10:44:31 +08001#
2# Copyright (C) 2007-2021 OpenWrt.org
3# Copyright (C) 2010 Vertical Communications
4#
5# This is free software, licensed under the GNU General Public License v2.
6# See /LICENSE for more information.
7#
8
9include $(TOPDIR)/rules.mk
10include $(INCLUDE_DIR)/kernel.mk
11include $(INCLUDE_DIR)/version.mk
12include $(INCLUDE_DIR)/feeds.mk
13
14PKG_NAME:=mbtk-rootfs
15PKG_VERSION:=1.0
16PKG_RELEASE:=1
17
18PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
19PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
20SVC_SOURCE_DIR:=$(TOPDIR)/mbtk/rootfs
21PKG_SOURCE_DIR:=$(SVC_SOURCE_DIR) $(STAGING_DIR)/usr/include $(STAGING_DIR)/usr/lib
22ROOTFS_DIR:=$(BUILD_DIR)/root-mmp
23
24PKG_BUILD_PARALLEL:=0
25
26include $(INCLUDE_DIR)/package.mk
27
28define Package/mbtk-rootfs
29 SECTION:=mbtk-rootfs
30 CATEGORY:=service
31 TITLE:=MBTK rootfs solution
32 DEPENDS:= +liblog +libubox +libubus +audio_if +libjson-c +zlib +libopenssl +libblobmsg-json
33endef
34
35define Package/$(PKG_NAME)/extra_provides
36 echo "libdnet.so.1"; \
b.liuc8e07a12025-05-14 21:01:04 +080037 echo "cfg80211.ko"; \
38 echo "libhttpclient.so";
b.liud440f9f2025-04-18 10:44:31 +080039endef
40
41define Package/mbtk-rootfs/description
42 mbtk-rootfs
43endef
44
45define Build/Compile
46 @echo "Do nothing."
47endef
48
49define Build/Clean
50 @echo "Do nothing."
51endef
52
53define Build/InstallDev
54 @echo "InstallDev-1 $(1)"
55 @echo "InstallDev-2 $(PKG_BUILD_DIR)"
56 @echo "InstallDev-3 $(PKG_SOURCE_DIR)"
57 @echo "InstallDev-4 $(SVC_SOURCE_DIR)"
58 @echo "InstallDev-5 $(STAGING_DIR)"
59 @echo "InstallDev-6 $(ROOTFS_DIR)"
60 $(INSTALL_DIR) $(ROOTFS_DIR)/lib
61 $(INSTALL_DIR) $(ROOTFS_DIR)/bin
62 $(INSTALL_DIR) $(ROOTFS_DIR)/etc
63 $(INSTALL_DIR) $(ROOTFS_DIR)/usr
64
65 $(CP) -rf $(PKG_BUILD_DIR)/ipkg-asr*/$(PKG_NAME)/* $(ROOTFS_DIR)/
66 #$(CP) -rf $(PKG_BUILD_DIR)/ipkg-asr1806/$(PKG_NAME)/lib/* $(ROOTFS_DIR)/lib/
67 #$(CP) -rf $(PKG_BUILD_DIR)/ipkg-asr1806/$(PKG_NAME)/bin/* $(ROOTFS_DIR)/bin/
68 #$(CP) -rf $(PKG_BUILD_DIR)/ipkg-asr1806/$(PKG_NAME)/etc/* $(ROOTFS_DIR)/etc/
69endef
70
71define Package/mbtk-rootfs/install
72 @echo "install-1 $(1)"
73 @echo "install-2 $(PKG_BUILD_DIR)"
74 @echo "install-3 $(PKG_SOURCE_DIR)"
75 @echo "install-4 $(SVC_SOURCE_DIR)"
76 @echo "install-5 $(STAGING_DIR)"
77 $(INSTALL_DIR) $(1)/lib
78 $(INSTALL_DIR) $(1)/bin
79 $(INSTALL_DIR) $(1)/etc
80 $(INSTALL_DIR) $(1)/usr
81
82 $(CP) -rf $(SVC_SOURCE_DIR)/* $(1)/
83 #$(CP) -rf $(SVC_SOURCE_DIR)/lib/* $(1)/lib/
84 #$(CP) -rf $(SVC_SOURCE_DIR)/bin/* $(1)/bin/
85 #$(CP) -rf $(SVC_SOURCE_DIR)/etc/* $(1)/etc/
86endef
87
88$(eval $(call BuildPackage,mbtk-rootfs))