Skip to content

build: add meson build support to dev container#1141

Merged
gaoxueyu merged 1 commit intoIvorySQL:masterfrom
rophy:feat/dev-container
Jan 4, 2026
Merged

build: add meson build support to dev container#1141
gaoxueyu merged 1 commit intoIvorySQL:masterfrom
rophy:feat/dev-container

Conversation

@rophy
Copy link
Copy Markdown
Contributor

@rophy rophy commented Dec 25, 2025

Follows https://github.com/IvorySQL/IvorySQL/blob/master/.github/workflows/meson_build.yml as much as possible.

  • Install meson 1.0.1 and ninja 1.10.1 from source
  • Add python3-setuptools, curl, unzip as dependencies (seems included in Github pipeline nodes, need to install explicitly in dev container)
  • Document meson build in README.md

Summary by CodeRabbit

  • Documentation

    • Added "Meson Build (Alternative)" docs describing how to configure, build, and run the project using Meson/Ninja; includes note about starting from a clean source tree.
    • Added CI FormatCheck workflow documentation for formatting/style checks.
  • Chores

    • Updated development container to include additional build tools, compilers, libraries, locale support, and utilities to support alternative build workflows.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Dec 25, 2025

📝 Walkthrough

Walkthrough

Adds tooling and packages to the development container (meson/ninja built from source, setuptools, curl/unzip, LLVM/system libs, tini/sudo) and documents an alternative Meson-based build workflow in the README; no public API changes.

Changes

Cohort / File(s) Summary
Development Container Setup
.devcontainer/Dockerfile
Adds curl and unzip; includes python3-setuptools; builds meson and ninja from source via multi-step install and cleanup; expands apt packages with llvm/clang, liblz4-dev, libselinux1-dev, libsystemd-dev, libgssapi-krb5-2, locales, sudo, and tini; retains locale-gen.
Documentation Updates
README.md
Adds "Meson Build (Alternative)" section with meson/ninja configuration, build, and run steps plus note about requiring a clean source tree; documents a FormatCheck CI workflow mention.

Sequence Diagram(s)

(omitted)

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

  • feat: dev container #982: Overlapping changes to .devcontainer/Dockerfile and README affecting dev-container tooling and build instructions.

Poem

🐰 I dug a burrow, found some tools,

Meson, Ninja—no more fools.
Curl to fetch and zip to play,
Containers hum and build away.
Hop on, devs, let's ship today! 🥕

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'build: add meson build support to dev container' directly and clearly summarizes the main change—adding Meson build support to the development container, which aligns with the PR's primary objectives of installing Meson/Ninja and updating dev container configuration.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

📜 Recent review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f380cdd and 8713046.

📒 Files selected for processing (2)
  • .devcontainer/Dockerfile
  • README.md
🚧 Files skipped from review as they are similar to previous changes (2)
  • .devcontainer/Dockerfile
  • README.md
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (6)
  • GitHub Check: meson_build (ubuntu-latest)
  • GitHub Check: oracle_pg_regression (ubuntu-latest)
  • GitHub Check: contrib_regression
  • GitHub Check: oracle_regression (ubuntu-latest)
  • GitHub Check: build (ubuntu-latest)
  • GitHub Check: pg_regression (ubuntu-latest)

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6fda66f and f380cdd.

📒 Files selected for processing (2)
  • .devcontainer/Dockerfile
  • README.md
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (6)
  • GitHub Check: pg_regression (ubuntu-latest)
  • GitHub Check: build (ubuntu-latest)
  • GitHub Check: oracle_regression (ubuntu-latest)
  • GitHub Check: meson_build (ubuntu-latest)
  • GitHub Check: contrib_regression
  • GitHub Check: oracle_pg_regression (ubuntu-latest)
🔇 Additional comments (3)
README.md (1)

65-82: Well-documented Meson build workflow.

The alternative Meson build instructions are clear, well-structured, and include a helpful note about the clean source tree requirement. The commands follow standard meson/ninja conventions and align well with the PR objectives.

.devcontainer/Dockerfile (2)

13-14: LGTM!

The curl and unzip packages are necessary dependencies for downloading and extracting the meson/ninja archives. The comment clearly documents their purpose.


22-22: LGTM!

The python3-setuptools package is correctly added as a dependency for the meson installation process.

Comment thread .devcontainer/Dockerfile
Comment on lines +39 to +46
# Install meson and ninja from source (matching workflow versions)
RUN curl -L "https://github.com/mesonbuild/meson/releases/download/1.0.1/meson-1.0.1.tar.gz" -o /tmp/meson-1.0.1.tar.gz \
&& curl -L "https://github.com/ninja-build/ninja/releases/download/v1.10.1/ninja-linux.zip" -o /tmp/ninja-linux.zip \
&& unzip -o /tmp/ninja-linux.zip -d /tmp \
&& cp /tmp/ninja /usr/bin/ \
&& tar xzf /tmp/meson-1.0.1.tar.gz -C /tmp \
&& cd /tmp/meson-1.0.1 && python3 setup.py install \
&& rm -rf /tmp/meson-1.0.1* /tmp/ninja*
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot Dec 25, 2025

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

# First, locate and read the Dockerfile
fd "Dockerfile" .devcontainer

Repository: IvorySQL/IvorySQL

Length of output: 85


🏁 Script executed:

# Read the specific lines mentioned in the review
cat -n .devcontainer/Dockerfile | sed -n '35,50p'

Repository: IvorySQL/IvorySQL

Length of output: 857


🌐 Web query:

meson build system python3 setup.py install deprecated

💡 Result:

Short answer: Yes — invoking python setup.py install (or other setup.py CLI commands) is deprecated. Use PEP 517/518 based tooling instead (e.g. declare a build backend in pyproject.toml and install with pip or use a modern backend such as meson-python when you build native extensions).

What to do:

  • Replace python setup.py install with python -m pip install . (or python -m pip install --editable . for editable installs). [1]
  • If your project builds compiled code, consider using Meson via the meson-python backend and declare it in pyproject.toml so pip/PEP 517 can build it. NumPy’s migration guide explicitly recommends Meson / meson-python for compiled projects. [2]
  • pip/setuptools are moving away from special-casing setup.py; enable/use PEP 517 mode (pip’s default will be PEP 517) to avoid deprecation warnings. [3]

Sources:
[1] Python Packaging Guide — “Is setup.py deprecated?” (recommendations to use pip/build).
[2] NumPy migration guide — recommends Meson and meson-python for projects with compiled code.
[3] pip / pypa discussions about deprecating legacy setup.py build/install behavior.


🌐 Web query:

latest stable versions meson ninja build tools 2025

💡 Result:

  • Meson: 1.10.0 — released December 8, 2025. [1]
  • Ninja: 1.13.2 — released November 20, 2025. [2]

Sources:
[1] Meson release notes — Release notes for 1.10.0.
[2] ninja-build GitHub releases — v1.13.2.


🏁 Script executed:

# Search for CI workflow files and version references
find . -type f \( -name "*.yml" -o -name "*.yaml" \) | grep -E "(workflow|ci|github)" | head -20

Repository: IvorySQL/IvorySQL

Length of output: 466


🏁 Script executed:

# Search for meson and ninja version references in workflow files
rg "meson.*1\.0\.1|ninja.*1\.10\.1" --type yaml

Repository: IvorySQL/IvorySQL

Length of output: 43


🏁 Script executed:

# Search more broadly for version specifications
rg "meson|ninja" --type yaml -A 2 -B 2 | grep -E "(version|release|download)" | head -30

Repository: IvorySQL/IvorySQL

Length of output: 195


🏁 Script executed:

# Read the meson_build.yml workflow
cat -n .github/workflows/meson_build.yml | head -80

Repository: IvorySQL/IvorySQL

Length of output: 1773


🏁 Script executed:

# Check if meson/ninja versions are specified in any workflow
rg "meson|ninja" .github/workflows/ -A 3 | head -60

Repository: IvorySQL/IvorySQL

Length of output: 1473


🏁 Script executed:

# Check if there's a pyproject.toml or setup.py in meson directory
find . -maxdepth 3 -name "pyproject.toml" -o -name "setup.py" | head -20

Repository: IvorySQL/IvorySQL

Length of output: 43


Update meson installation to use pip and address deprecated setup.py, plus coordinate version updates with CI workflow.

The installation block has several areas for improvement, and notably the versions are intentionally pinned to match .github/workflows/meson_build.yml:

  1. Deprecated setup.py install (Line 45): The python3 setup.py install command is deprecated. Use pip3 install /tmp/meson-1.0.1/ instead.

  2. Missing checksum verification: The downloads are not verified with checksums. Consider adding SHA256 verification for security.

  3. Old pinned versions: Meson 1.0.1 and Ninja 1.10.1 are pinned to match the CI workflow, but both are dated (2023 and 2020 respectively). If updating to newer versions (current: Meson 1.10.0, Ninja 1.13.2), you must also update .github/workflows/meson_build.yml lines 27-28 to keep them synchronized.

🤖 Prompt for AI Agents
.devcontainer/Dockerfile lines 39-46: the meson install uses deprecated python3
setup.py install and lacks checksum verification and coordinated CI version
updates; replace the setup.py install with pip3 install /tmp/meson-1.0.1/ (or
pip3 install meson==<version> if you update the pinned version), add SHA256
checksum verification for both the meson tarball and ninja zip after download
and before extraction, and if you bump meson/ninja versions update the matching
pins in .github/workflows/meson_build.yml (lines ~27-28) so the Dockerfile and
CI stay synchronized.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes, intentionally pin the same version as CI pipeline.

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.

@rophy, understood — keeping the versions synchronized with the CI pipeline is a good practice for consistency.

However, there are still two concerns independent of the version choice:

  1. Deprecated installation method (Line 45): The python3 setup.py install command is deprecated. Even with Meson 1.0.1, you should use pip3 install /tmp/meson-1.0.1/ instead to avoid deprecation warnings and follow modern Python packaging standards.

  2. Missing checksum verification: For security, consider adding SHA256 verification after downloading the tarballs:

    RUN curl -L "https://github.com/mesonbuild/meson/releases/download/1.0.1/meson-1.0.1.tar.gz" -o /tmp/meson-1.0.1.tar.gz \
        && echo "<SHA256_HASH>  /tmp/meson-1.0.1.tar.gz" | sha256sum -c - \
        && curl -L "https://github.com/ninja-build/ninja/releases/download/v1.10.1/ninja-linux.zip" -o /tmp/ninja-linux.zip \
        && echo "<SHA256_HASH>  /tmp/ninja-linux.zip" | sha256sum -c - \
        && unzip -o /tmp/ninja-linux.zip -d /tmp \
        && cp /tmp/ninja /usr/bin/ \
        && tar xzf /tmp/meson-1.0.1.tar.gz -C /tmp \
        && cd /tmp/meson-1.0.1 && pip3 install . \
        && rm -rf /tmp/meson-1.0.1* /tmp/ninja*

Would you like to address these improvements while keeping the version pinning?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

nah, I'm fine with strictly copying what CI piepline does.

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.

@rophy, understood — I respect your decision to keep the dev container setup aligned with the CI pipeline exactly as-is. Feel free to reach out if you need anything else!

@rophy rophy mentioned this pull request Dec 25, 2025
4 tasks
- Install meson 1.0.1 and ninja 1.10.1 from source
- Add python3-setuptools, curl, unzip as dependencies
- Document meson build in README.md
@rophy rophy force-pushed the feat/dev-container branch from f380cdd to 8713046 Compare December 25, 2025 12:06
@rophy
Copy link
Copy Markdown
Contributor Author

rophy commented Dec 25, 2025

@OreoYang I'm not familar with meson build, the README is mainly to educate someone like me. Kindly help to advise.

  1. For meson build do I still run make oracle-check-world?
  2. It seems meson_build pipeline only runs build, can we make it run some tests?

@OreoYang
Copy link
Copy Markdown
Collaborator

OreoYang commented Dec 26, 2025

@OreoYang I'm not familar with meson build, the README is mainly to educate someone like me. Kindly help to advise.

  1. For meson build do I still run make oracle-check-world?
  2. It seems meson_build pipeline only runs build, can we make it run some tests?

Yes, currently the CI only performs meson build and does support meson test.
That's because Oracle's meson test framework hasn't been set up; supporting meson build is needed because building the WASM operating system with buildroot requires meson build.

In other words, currently there is no CI in place to ensure that the newly added features can run correctly in images built with meson, and manual review is required.

take PR #998 for example
You just need to place the newly added .c file in the meson.build file.

diff --git a/contrib/ivorysql_ora/meson.build b/contrib/ivorysql_ora/meson.build
index d16cba8d7b..b932862ce9 100644
--- a/contrib/ivorysql_ora/meson.build
+++ b/contrib/ivorysql_ora/meson.build
@@ -23,6 +23,7 @@ ivorysql_ora_sources = files(
   'src/builtin_functions/datetime_datatype_functions.c',
   'src/builtin_functions/numeric_datatype_functions.c',
   'src/builtin_functions/misc_functions.c',
+  'src/builtin_packages/dbms_output/dbms_output.c',
   'src/merge/ora_merge.c',
   'src/sysview/sysview_functions.c',
   'src/xml_functions/ora_xml_functions.c',

@gaoxueyu gaoxueyu merged commit 5b69fab into IvorySQL:master Jan 4, 2026
6 checks passed
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