Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ ide-prepare:
${CPP2V}

.PHONY: stage1
stage1: ide-prepare ast-prepare-bluerock
stage1: dev-check-ver-full-workspace ide-prepare ast-prepare-bluerock

.PHONY: pipeline-deps
pipeline-deps:
Expand Down
11 changes: 8 additions & 3 deletions dev/check_ver/clang.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,14 @@

PROG="clang"
URL="https://apt.llvm.org"
MIN="18.0.0"
FIRST_UNSUPPORTED="22.0.0"
RECOMMENDED="19.*.*"
FIRST_UNSUPPORTED="23.0.0"
if [[ $# -gt 0 ]] && [[ "$1" -eq "--full-workspace" ]]; then
MIN="22.0.0"
RECOMMENDED="22.*.*"
else
MIN="18.0.0"
RECOMMENDED="19.*.*"
fi
Comment on lines -8 to +15

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
MIN="18.0.0"
FIRST_UNSUPPORTED="22.0.0"
RECOMMENDED="19.*.*"
FIRST_UNSUPPORTED="23.0.0"
if [[ $# -gt 0 ]] && [[ "$1" -eq "--full-workspace" ]]; then
MIN="22.0.0"
RECOMMENDED="22.*.*"
else
MIN="18.0.0"
RECOMMENDED="19.*.*"
fi
MIN="19.0.0"
RECOMMENDED="22.*.*"
FIRST_UNSUPPORTED="23.0.0"
if [[ $# -gt 0 ]] && [[ "$1" -eq "--full-workspace" ]]; then
MIN="22.0.0"
fi


print_ver() {
VER="$(clang --version | grep "clang version" | sed -r 's/^.*clang version ([0-9.]+).*$/\1/')"
Expand Down
8 changes: 6 additions & 2 deletions dev/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,20 @@

define check_ver_target
DEV_CHECK_VER_TARGETS += dev-check-ver-$1
.PHONY: dev-check-ver-$1
.PHONY: dev-check-ver-$1 dev-check-ver-$1-full-workspace
dev-check-ver-$1: dev/check_ver/$1.sh
$$(Q)./$$<
endef

dev-check-ver-clang-full-workspace: dev/check_ver/clang.sh
$$(Q)./$$< --full-workspace

DEV_PROGS = make clang opam rust uv bash
$(foreach prog,$(DEV_PROGS),$(eval $(call check_ver_target,$(prog))))

.PHONY: dev-check-ver
dev-check-ver: $(DEV_CHECK_VER_TARGETS) dev-check-ver-sed
dev-check-ver-full-workspace: dev-check-ver dev-check-ver-clang-full-workspace

.PHONY: dev-check-ver-sed
# Reject systems where `sed` is not GNU `sed` and `gsed` is not available.
Expand All @@ -22,7 +26,7 @@ dev-check-ver-sed:

# Setting up the development environment.

.PHONY: dev-setup
.PHONY: dev-setup dev-setup-full-workspace

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
.PHONY: dev-setup dev-setup-full-workspace
.PHONY: dev-setup

Not there.

dev-setup: dev-check-ver dev-setup-opam

.PHONY: dev-setup-opam
Expand Down