fix collecting package metadata on freebsd

SVN-Revision: 5655
This commit is contained in:
Felix Fietkau 2006-11-27 03:33:19 +00:00
parent 368dc17432
commit a1ac6d1d9f
1 changed files with 20 additions and 14 deletions

View File

@ -143,31 +143,35 @@ define BuildPackage
IDEPEND_$(1):=$$(strip $$(DEPENDS)) IDEPEND_$(1):=$$(strip $$(DEPENDS))
ifneq ($(DUMP),) ifneq ($(DUMP),)
DUMPINFO += \ dumpinfo: dumpinfo-$(1)
dumpinfo-$(1): FORCE
@$$(DUMPINFO_$(call shvar,$(1)))
DUMPINFO_$(call shvar,$(1)) += \
echo "Package: $(1)"; echo "Package: $(1)";
ifneq ($(MENU),) ifneq ($(MENU),)
DUMPINFO += \ DUMPINFO_$(call shvar,$(1)) += \
echo "Menu: $(MENU)"; echo "Menu: $(MENU)";
endif endif
ifneq ($(SUBMENU),) ifneq ($(SUBMENU),)
DUMPINFO += \ DUMPINFO_$(call shvar,$(1)) += \
echo "Submenu: $(SUBMENU)"; echo "Submenu: $(SUBMENU)";
ifneq ($(SUBMENUDEP),) ifneq ($(SUBMENUDEP),)
DUMPINFO += \ DUMPINFO_$(call shvar,$(1)) += \
echo "Submenu-Depends: $(SUBMENUDEP)"; echo "Submenu-Depends: $(SUBMENUDEP)";
endif endif
endif endif
ifneq ($(DEFAULT),) ifneq ($(DEFAULT),)
DUMPINFO += \ DUMPINFO_$(call shvar,$(1)) += \
echo "Default: $(DEFAULT)"; echo "Default: $(DEFAULT)";
endif endif
$(call shexport,Package/$(1)/description) $(call shexport,Package/$(1)/description)
DUMPINFO += \ DUMPINFO_$(call shvar,$(1)) += \
if [ "$$$$PREREQ_CHECK" = 1 ]; then echo "Prereq-Check: 1"; fi; \ if [ "$$$$PREREQ_CHECK" = 1 ]; then echo "Prereq-Check: 1"; fi; \
echo "Version: $(VERSION)"; \ echo "Version: $(VERSION)"; \
echo "Depends: $$(IDEPEND_$(1))"; \ echo "Depends: $$(IDEPEND_$(1))"; \
@ -179,22 +183,25 @@ define BuildPackage
echo -n "Description: "; \ echo -n "Description: "; \
getvar $(call shvar,Package/$(1)/description); \ getvar $(call shvar,Package/$(1)/description); \
else \ else \
echo "Description: $(DESCRIPTION)" | sed -e 's,\\,\n,g'; \ echo "Description: $(patsubst \\,\\\\,$(DESCRIPTION))" | perl -ne 's/\\/\n/g, print'; \
fi; fi;
ifneq ($(URL),) ifneq ($(URL),)
DUMPINFO += \ DUMPINFO_$(call shvar,$(1)) += \
echo; \ echo; \
echo "$(URL)"; echo "$(URL)";
endif endif
DUMPINFO += \ DUMPINFO_$(call shvar,$(1)) += \
echo "@@"; echo "@@";
$(call shexport,Package/$(1)/config) $(call shexport,Package/$(1)/config)
DUMPINFO += \ DUMPINFO_$(call shvar,$(1)) += \
if isset $(call shvar,Package/$(1)/config); then echo "Config: "; getvar $(call shvar,Package/$(1)/config); fi; \ if isset $(call shvar,Package/$(1)/config); then \
echo "@@"; echo "Config: "; \
getvar $(call shvar,Package/$(1)/config); \
echo "@@"; \
fi;
endif endif
@ -331,8 +338,7 @@ define Build/Compile
endef endef
ifneq ($(DUMP),) ifneq ($(DUMP),)
dumpinfo: FORCE dumpinfo:
@$(DUMPINFO)
else else
$(PACKAGE_DIR): $(PACKAGE_DIR):
mkdir -p $@ mkdir -p $@