Skip to content

Conversation

@tuhaihe
Copy link
Member

@tuhaihe tuhaihe commented Sep 11, 2025

This commit is used to support the release build udner macOS and enhance the developer experience for running the script.

Main changes:

  • Enforce GNU tar and sha512sum usage on macOS for generating artfacts
  • Clean macOS extended attributes to prevent compilation errors on Linux
  • Add platform and tool validation with installation guidance
  • Support RC tag validation with base version matching in source
  • Add interactive confirmations and enhanced verification steps

Fixes #ISSUE_Number

What does this PR do?

Type of Change

  • Bug fix (non-breaking change)
  • New feature (non-breaking change)
  • Breaking change (fix or feature with breaking changes)
  • Documentation update

Breaking Changes

Test Plan

  • Unit tests added/updated
  • Integration tests added/updated
  • Passed make installcheck
  • Passed make -C src/test installcheck-cbdb-parallel

Impact

Performance:

User-facing changes:

Dependencies:

Checklist

Additional Context

CI Skip Instructions


@jiaqizho
Copy link
Contributor

Has cloudberrydb been verified to compile with clang++ on macOS? I am curious why it is necessary to build the release package on MacOS?

@tuhaihe
Copy link
Member Author

tuhaihe commented Oct 9, 2025

Has cloudberrydb been verified to compile with clang++ on macOS? I am curious why it is necessary to build the release package on MacOS?

Hi @jiaqizho, thanks for your question. This script is just used to archive the source code into a *.tar.gz file on macOS (For Apache release, it's only in the source form), but it is not used for building Cloudberry on macOS.

Given that most of the Cloudberry developers are using macOS, it's necessary to support release managers to deliver a source code archive file under macOS. Or else, we need to create a Linux VM or Cloud Machine to do this.

The commit message may be a little confusing. I will revise it later.

This commit is used to make an ASF-release (tarball) file for committers
under macOS machine and enhance the developer experience for running the
script.

Main changes:
* Enforce GNU tar and sha512sum usage on macOS for generating artfacts
* Clean macOS extended attributes to prevent compilation errors on Linux
* Add platform and tool validation with installation guidance
* Support RC tag validation with base version matching in source
* Add interactive confirmations and enhanced verification steps
@tuhaihe
Copy link
Member Author

tuhaihe commented Jan 29, 2026

Output record:

[root@ecs-a591 cloudberry]# ./devops/release/cloudberry-release.sh -s -t 2.1.0-incubating-rc1 --gpg-user your@apache.org -k
INFO: GPG signing has been intentionally skipped (--skip-signing).

=================================================================
>> Platform and Tool Detection
=================================================================
Platform detected: Linux

[OK] SHA-512 tool: sha512sum
[OK] Tar tool: tar
- GPG tool: skipped (--skip-signing enabled)
[OK] XML tool: xmllint

Press Enter or type y/yes to continue, or 'n' to exit: y

=================================================================
>> Validating Version Consistency
=================================================================
Version validation strategy:
  Tag: 2.1.0-incubating-rc1
  Base version (for source files): 2.1.0-incubating
Version consistency verified
    Release Tag   : 2.1.0-incubating-rc1
    Base Version  : 2.1.0-incubating
    configure.ac  : 2.1.0-incubating
    configure     : 2.1.0-incubating
    pom.xml       : 2.1.0-incubating
    gpversion.py  : 2,99

Press Enter or type y/yes to continue, or 'n' to exit: y

=================================================================
>> Checking the state of the Tag
=================================================================
INFO: Tag '2.1.0-incubating-rc1' does not yet exist. It will be created during staging.

Press Enter or type y/yes to continue, or 'n' to exit: y

=================================================================
>> Checking Git Submodules
=================================================================
Initialized  : contrib/pax_storage/src/cpp/contrib/googlebench
Initialized  : contrib/pax_storage/src/cpp/contrib/googletest
Initialized  : contrib/pax_storage/src/cpp/contrib/tabulate
Initialized  : dependency/yyjson
Initialized  : gpcontrib/gpcloud/test/googletest

=================================================================
>> Checking GIT_USER_NAME and GIT_USER_EMAIL values
=================================================================
Git User Info:
    user.name     : Your Name
    user.email    : you@example.com

=================================================================
>> Staging release: 2.1.0-incubating-rc1
=================================================================
You are about to create tag '2.1.0-incubating-rc1'. Continue? [y/N] y
Creating BUILD_NUMBER file with commit hash

Tag Summary
2.1.0-incubating-rc1 (tag object): 10f86505f5c26578892ae3a535bd268df31521aa
    Points to commit: 9ac39f8639e234e71e0417ed881d262ff1a9556f
9ac39f8639e  (HEAD -> REL_2_STABLE, tag: 2.1.0-incubating-rc1)

Press Enter or type y/yes to continue, or 'n' to exit: y

=================================================================
>> Creating Source Tarball
=================================================================
Archiving submodule: contrib/pax_storage/src/cpp/contrib/googlebench
Archiving submodule: contrib/pax_storage/src/cpp/contrib/googletest
Archiving submodule: contrib/pax_storage/src/cpp/contrib/tabulate
Archiving submodule: dependency/yyjson
Archiving submodule: gpcontrib/gpcloud/test/googletest
Archive saved to: apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz

Press Enter or type y/yes to continue, or 'n' to exit: y

=================================================================
>> Generating SHA-512 Checksum
=================================================================

Generating SHA-512 checksum
Checksum saved to: apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz.sha512

Press Enter or type y/yes to continue, or 'n' to exit: y

=================================================================
>> Signing with GPG key: your@apache.org
=================================================================
INFO: Skipping tarball signing as requested (--skip-signing)

=================================================================
>> Moving Artifacts to /root/artifacts
=================================================================

Moving release artifacts to: /root/artifacts
renamed 'apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz' -> '/root/artifacts/apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz'
renamed 'apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz.sha512' -> '/root/artifacts/apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz.sha512'

Press Enter or type y/yes to continue, or 'n' to exit: y

=================================================================
>> Verifying sha512 (/root/artifacts/apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz.sha512) Release Artifact
=================================================================
apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz: OK

Press Enter or type y/yes to continue, or 'n' to exit: y

=================================================================
>> Verifying GPG Signature (/root/artifacts/apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz.asc) Release Artifact
=================================================================
INFO: Signature verification skipped (--skip-signing). Signature is only available when generated via this script.

Press Enter or type y/yes to continue, or 'n' to exit: y

=================================================================
>> Release candidate for 2.1.0-incubating-rc1 staged successfully
=================================================================
[root@ecs-a591 cloudberry]# ls
aclocal.m4          contrib          getversion      licenses    python-dependencies.txt
BUILD_NUMBER        CONTRIBUTING.md  GNUmakefile.in  Makefile    README.apache.md
CODE_OF_CONDUCT.md  dependency       gpAux           mcp-server  README.md
config              devops           gpcontrib       NOTICE      SECURITY.md
configure           DISCLAIMER       gpMgmt          pom.xml     sonar-project.properties
configure.ac        doc              LICENSE         putversion  src
[root@ecs-a591 cloudberry]# cd ..
[root@ecs-a591 ~]# ls artifacts/
apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz  apache-cloudberry-2.1.0-incubating-rc1-src.tar.gz.sha512

@tuhaihe tuhaihe changed the title Release: add script support under macOS CI: add ASF-release support under macOS Jan 29, 2026
@tuhaihe
Copy link
Member Author

tuhaihe commented Jan 29, 2026

Would like to merge this tool to the main and cherry-pick it to the REL_2_STABLE for a better release. Thanks!

Copy link
Contributor

@leborchuk leborchuk left a comment

Choose a reason for hiding this comment

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

Checked on my MacOS, seems to work well

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants