Skip to content

Commit 9a5fb00

Browse files
author
Davide Melfi
committed
build: removed useless profile specific builds
1 parent 45b43fe commit 9a5fb00

File tree

1 file changed

+24
-16
lines changed
  • aws-lambda-java-runtime-interface-client

1 file changed

+24
-16
lines changed

aws-lambda-java-runtime-interface-client/Makefile

Lines changed: 24 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -15,57 +15,63 @@ endif
1515
# making it possible to publish resulting artifacts to a codeartifact maven repository
1616
-include ric-dev-environment/codeartifact-repo.mk
1717

18-
.PHONY: target
18+
1919
target:
2020
$(info ${HELP_MESSAGE})
2121
@exit 0
2222

23-
.PHONY: test
23+
2424
test:
2525
mvn test $(EXTRA_LOAD_ARG)
2626

27-
.PHONY: setup-codebuild-agent
27+
2828
setup-codebuild-agent:
2929
docker build -t codebuild-agent \
3030
--build-arg ARCHITECTURE=$(ARCHITECTURE_ALIAS) \
3131
- < test/integration/codebuild-local/Dockerfile.agent
3232

33-
.PHONY: test-smoke
33+
3434
test-smoke: setup-codebuild-agent
3535
CODEBUILD_IMAGE_TAG=codebuild-agent test/integration/codebuild-local/test_one.sh test/integration/codebuild/buildspec.os.alpine.yml alpine 3.15 corretto11 linux/amd64
3636
CODEBUILD_IMAGE_TAG=codebuild-agent test/integration/codebuild-local/test_one.sh test/integration/codebuild/buildspec.os.alpine.yml alpine 3.15 corretto11 linux/arm64/v8
3737
CODEBUILD_IMAGE_TAG=codebuild-agent test/integration/codebuild-local/test_one.sh test/integration/codebuild/buildspec.os.amazoncorretto.yml amazoncorretto amazoncorretto 11 linux/amd64
3838
CODEBUILD_IMAGE_TAG=codebuild-agent test/integration/codebuild-local/test_one.sh test/integration/codebuild/buildspec.os.amazoncorretto.yml amazoncorretto amazoncorretto 11 linux/arm64/v8
3939

40-
.PHONY: test-integ
40+
4141
test-integ: setup-codebuild-agent
4242
CODEBUILD_IMAGE_TAG=codebuild-agent test/integration/codebuild-local/test_all.sh test/integration/codebuild
4343

4444
# Command to run everytime you make changes to verify everything works
45-
.PHONY: dev
45+
4646
dev: test
4747

4848
# Verifications to run before sending a pull request
49-
.PHONY: pr
49+
5050
pr: test test-smoke
5151

52-
.PHONY: build
52+
53+
# The default `mvn clean install` builds all 4 native .so variants (x86_64/aarch64 × glibc/musl)
54+
# and bundles them into a single jar (see build-jni-lib.sh), runs the tests for the host
55+
# environment, and updates coverage data. This is sufficient for what we want to do here.
56+
#
57+
# Running profile-specific builds (e.g., `mvn install -P linux-aarch64`) does NOT test the
58+
# cross-compiled .so — JniHelper.load() tries each .so in order and always loads the first
59+
# one matching the host platform (linux-x86_64 on GitHub Actions runners), so the other
60+
# variants are never exercised.
61+
#
62+
# Platform-specific tests are run through test-smoke via codebuild containers.
63+
5364
build:
54-
mvn clean install $(EXTRA_LOAD_ARG)
55-
mvn install -P linux-x86_64 $(EXTRA_LOAD_ARG)
56-
mvn install -P linux_musl-x86_64 $(EXTRA_LOAD_ARG)
57-
mvn install -P linux-aarch64 $(EXTRA_LOAD_ARG)
58-
mvn install -P linux_musl-aarch64 $(EXTRA_LOAD_ARG)
65+
mvn clean install $(EXTRA_LOAD_ARG)
5966

60-
.PHONY: publish
6167
publish:
6268
./ric-dev-environment/publish_snapshot.sh
6369

64-
.PHONY: publish
70+
6571
test-publish:
6672
./ric-dev-environment/test-platform-specific-jar-snapshot.sh
6773

68-
.PHONY: test-rie
74+
6975
test-rie:
7076
./scripts/test-rie.sh "EchoHandler::handleRequest"
7177

@@ -80,3 +86,5 @@ TARGETS
8086
test Run the Unit tests.
8187
test-rie Build and test RIC locally with Lambda Runtime Interface Emulator. (Requires building the project first)
8288
endef
89+
90+
.PHONY: target test setup-codebuild-agent test-smoke test-integ dev pr build publish publish test-rie

0 commit comments

Comments
 (0)