Skip to content

Commit

Permalink
feat: Build linux branches in addition to releases
Browse files Browse the repository at this point in the history
  • Loading branch information
mpolitzer committed Feb 7, 2024
1 parent 87c96cb commit ab00877
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,15 @@ run-as-root:
-w $(CONTAINER_BASE) \
cartesi/toolchain:$(TOOLCHAIN_TAG) $(CONTAINER_COMMAND)

# fetch the public cartesi linux sources if none was provided
ifneq ($(DEV),y)
$(KERNEL_SRCPATH):
@wget -O $@ https://github.com/cartesi/linux/archive/v$(KERNEL_VERSION).tar.gz
else
$(KERNEL_SRCPATH):
wget -O $@ https://github.com/cartesi/linux/archive/refs/heads/$(KERNEL_VERSION).tar.gz
$(MAKE) shasumfile # rebuild the shasumfile
sed -i 's#CT_LINUX_CUSTOM_LOCATION=".\+"#CT_LINUX_CUSTOM_LOCATION="/tmp/build/linux-$(KERNEL_VERSION).tar.gz"#' $(TOOLCHAIN_CONFIG) # patch the config file
endif

shasumfile: $(KERNEL_SRCPATH)
@shasum -a 256 $^ > $@
Expand Down

0 comments on commit ab00877

Please sign in to comment.