dahdi-tools: add PKG_BUILD_PARALLEL & PKG_INSTALL 398/head
authorSebastian Kemper <sebastian_ml@gmx.net>
Sat, 29 Dec 2018 10:44:56 +0000 (11:44 +0100)
committerSebastian Kemper <sebastian_ml@gmx.net>
Sat, 29 Dec 2018 10:44:58 +0000 (11:44 +0100)
Cleans up the install sections while replacing PKG_BUILD_DIR with
PKG_INSTALL_DIR, too.

Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
libs/dahdi-tools/Makefile

index dc66764fc5e9c68e22d5664b20ba5a06a469a7e5..523f68c41d76a873123b3fcd61ec052a8570b1c0 100644 (file)
@@ -19,8 +19,12 @@ PKG_LICENSE:=GPL-2.0
 PKG_LICENSE_FILES:=LICENSE
 PKG_MAINTAINER:=Vittorio Gambaletta <openwrt@vittgam.net>
 
+PKG_BUILD_PARALLEL:=1
+
 PKG_FIXUP:=autoreconf
 
+PKG_INSTALL:=1
+
 include $(INCLUDE_DIR)/package.mk
 
 define Package/dahdi-cfg/Default
@@ -52,30 +56,28 @@ CONFIGURE_ARGS+=--disable-silent-rules
 
 define Build/InstallDev
        $(INSTALL_DIR) $(1)/usr/lib
-       $(CP) $(PKG_BUILD_DIR)/.libs/*.so* $(1)/usr/lib/
-       $(CP) $(PKG_BUILD_DIR)/.libs/*.a $(1)/usr/lib/
-
+       $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtonezone.{a,so*} \
+               $(1)/usr/lib/
        $(INSTALL_DIR) $(1)/usr/include/dahdi
-       $(INSTALL_DATA) $(PKG_BUILD_DIR)/tonezone.h $(1)/usr/include/dahdi/
+       $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/dahdi/tonezone.h \
+               $(1)/usr/include/dahdi/
 endef
 
 define Package/dahdi-cfg/install
        $(INSTALL_DIR) $(1)/usr/sbin
-       $(INSTALL_BIN) $(PKG_BUILD_DIR)/.libs/dahdi_cfg $(1)/usr/sbin/
-       $(INSTALL_BIN) $(PKG_BUILD_DIR)/dahdi_scan $(1)/usr/sbin/
-       $(INSTALL_BIN) $(PKG_BUILD_DIR)/fxotune $(1)/usr/sbin/
+       $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/{dahdi_cfg,dahdi_scan,fxotune} \
+               $(1)/usr/sbin/
 endef
 
 define Package/dahdi-monitor/install
        $(INSTALL_DIR) $(1)/usr/sbin
-       $(INSTALL_BIN) $(PKG_BUILD_DIR)/dahdi_monitor $(1)/usr/sbin/
-       $(INSTALL_BIN) $(PKG_BUILD_DIR)/dahdi_speed $(1)/usr/sbin/
-       $(INSTALL_BIN) $(PKG_BUILD_DIR)/dahdi_test $(1)/usr/sbin/
+       $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/{dahdi_monitor,dahdi_speed,dahdi_test} \
+               $(1)/usr/sbin/
 endef
 
 define Package/dahdi-tools-libtonezone/install
        $(INSTALL_DIR) $(1)/usr/lib
-       $(CP) $(PKG_BUILD_DIR)/.libs/libtonezone.so* $(1)/usr/lib/
+       $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtonezone.so* $(1)/usr/lib/
 endef
 
 $(eval $(call BuildPackage,dahdi-cfg))