fix: correct arch naming and build order for ARM64 packages
Some checks are pending
CI/CD / lint (push) Successful in 50s
CI/CD / test (push) Successful in 1m4s
CI/CD / typecheck (push) Successful in 3m0s
CI/CD / build (amd64) (push) Successful in 2m22s
CI/CD / build (arm64) (push) Successful in 1m45s
CI/CD / publish-rpm (amd64) (push) Successful in 46s
CI/CD / publish-rpm (arm64) (push) Successful in 48s
CI/CD / publish-deb (amd64) (push) Successful in 58s
CI/CD / publish-deb (arm64) (push) Successful in 58s
CI/CD / smoke (push) Has started running

- nfpm.yaml: use ${NFPM_ARCH} (Go's ExpandEnv doesn't support :-default)
- arch-helper.sh: export RPM_ARCH (x86_64/aarch64) alongside NFPM_ARCH
- build-rpm/deb.sh: build TypeScript before running tests (tests need
  built @mcpctl/shared), generate Prisma client on fresh checkout
- Fix RPM filename matching to use aarch64 not arm64

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Michal Rydlikowski
2026-03-13 23:16:48 +00:00
parent c7c9f0923f
commit e4bff0ef89
7 changed files with 39 additions and 16 deletions

View File

@@ -3,7 +3,8 @@
# Source this file, then call: resolve_arch [target_arch]
#
# Outputs (exported):
# NFPM_ARCH — nfpm/deb/rpm arch name: "amd64" or "arm64"
# NFPM_ARCH — nfpm arch name: "amd64" or "arm64"
# RPM_ARCH — RPM arch name: "x86_64" or "aarch64"
# BUN_TARGET — bun cross-compile target (empty if native build)
# ARCH_SUFFIX — filename suffix for cross-compiled binaries (empty if native)
@@ -57,6 +58,13 @@ resolve_arch() {
fi
fi
export NFPM_ARCH BUN_TARGET ARCH_SUFFIX
# RPM uses different arch names than deb/nfpm
case "$NFPM_ARCH" in
amd64) RPM_ARCH="x86_64" ;;
arm64) RPM_ARCH="aarch64" ;;
*) RPM_ARCH="$NFPM_ARCH" ;;
esac
export NFPM_ARCH RPM_ARCH BUN_TARGET ARCH_SUFFIX
echo " Architecture: ${NFPM_ARCH} (native: ${native}${BUN_TARGET:+, cross-compiling via $BUN_TARGET})"
}