32e908abcb
* remove unused cryptographic implementations * update tooling Resolves: rhbz#1975437
43 lines
1.1 KiB
Makefile
43 lines
1.1 KiB
Makefile
ifndef VER
|
|
$(error VER is undefined)
|
|
endif
|
|
ifndef REL
|
|
$(error REL is undefined)
|
|
endif
|
|
|
|
NAME := d3-flame-graph
|
|
RPM_NAME := js-$(NAME)
|
|
SOURCE_DIR := $(NAME)-$(VER)
|
|
SOURCE_TAR := $(NAME)-$(VER).tar.gz
|
|
VENDOR_TAR := $(RPM_NAME)-vendor-$(VER)-$(REL).tar.xz
|
|
|
|
ALL_PATCHES := $(sort $(wildcard *.patch))
|
|
VENDOR_PATCHES := $(sort $(wildcard *.vendor.patch))
|
|
SOURCE_PATCHES := $(filter-out $(VENDOR_PATCHES),$(ALL_PATCHES))
|
|
|
|
all: $(SOURCE_TAR) $(VENDOR_TAR)
|
|
|
|
$(SOURCE_TAR):
|
|
spectool -g $(RPM_NAME).spec
|
|
|
|
$(VENDOR_TAR): $(SOURCE_TAR)
|
|
rm -rf $(SOURCE_DIR)
|
|
tar xf $(SOURCE_TAR)
|
|
|
|
# Patches to apply before vendoring
|
|
for patch in $(SOURCE_PATCHES); do echo $$patch; patch -d $(SOURCE_DIR) -p1 --fuzz=0 < $$patch; done
|
|
|
|
# Node.js
|
|
cd $(SOURCE_DIR) && yarn import && yarn install --pure-lockfile
|
|
./list_bundled_nodejs_packages.py $(SOURCE_DIR)/ >> $@.manifest
|
|
|
|
# Patches to apply after vendoring
|
|
for patch in $(VENDOR_PATCHES); do echo $$patch; patch -d $(SOURCE_DIR) -p1 --fuzz=0 < $$patch; done
|
|
|
|
# Create tarball
|
|
XZ_OPT=-9 tar cJf $@ \
|
|
$(SOURCE_DIR)/node_modules
|
|
|
|
clean:
|
|
rm -rf *.tar.gz *.tar.xz *.manifest *.rpm $(NAME)-*/
|