X-Git-Url: https://git.archive.openwrt.org/?a=blobdiff_plain;f=include%2Fpackage-ipkg.mk;h=eb4c874047e8a9e24a4d77b13f7ba66e1221cbb5;hb=eb2bd9d4ddb4bf2c64db6fe1f82684f8ae44e6bc;hp=5ea39e1b06edbf8393b93c8ea992fbbecf9012bb;hpb=b8f881a20eb0c839a0f949e5a16e92b8d78eb3d1;p=openwrt.git diff --git a/include/package-ipkg.mk b/include/package-ipkg.mk index 5ea39e1b06..eb4c874047 100644 --- a/include/package-ipkg.mk +++ b/include/package-ipkg.mk @@ -9,18 +9,19 @@ include $(INCLUDE_DIR)/feeds.mk # invoke ipkg-build with some default options IPKG_BUILD:= \ - $(STAGING_DIR_HOST)/bin/ipkg-build -c -o 0 -g 0 + $(SCRIPT_DIR)/ipkg-build -c -o 0 -g 0 IPKG_STATE_DIR:=$(TARGET_DIR)/usr/lib/opkg # 1: package name # 2: variable name # 3: variable suffix +# 4: file is a script define BuildIPKGVariable ifdef Package/$(1)/$(2) $$(IPKG_$(1)) : VAR_$(2)$(3)=$$(Package/$(1)/$(2)) $(call shexport,Package/$(1)/$(2)) - $(1)_COMMANDS += echo "$$$$$$$$$(call shvar,Package/$(1)/$(2))" > $(2)$(3); + $(1)_COMMANDS += echo "$$$$$$$$$(call shvar,Package/$(1)/$(2))" > $(2)$(3); $(if $(4),chmod 0755 $(2)$(3);) endif endef @@ -125,10 +126,10 @@ ifeq ($(DUMP),) $(FixupReverseDependencies) $(eval $(call BuildIPKGVariable,$(1),conffiles)) - $(eval $(call BuildIPKGVariable,$(1),preinst)) - $(eval $(call BuildIPKGVariable,$(1),postinst,-pkg)) - $(eval $(call BuildIPKGVariable,$(1),prerm,-pkg)) - $(eval $(call BuildIPKGVariable,$(1),postrm)) + $(eval $(call BuildIPKGVariable,$(1),preinst,,1)) + $(eval $(call BuildIPKGVariable,$(1),postinst,-pkg,1)) + $(eval $(call BuildIPKGVariable,$(1),prerm,-pkg,1)) + $(eval $(call BuildIPKGVariable,$(1),postrm,,1)) $(STAGING_DIR_ROOT)/stamp/.$(1)_installed: $(STAMP_BUILT) rm -rf $(STAGING_DIR_ROOT)/tmp-$(1)