Skip to content

Check if project can be built on different distributions#9

Merged
HyperWinX merged 26 commits intomasterfrom
distro-ci
Apr 6, 2025
Merged

Check if project can be built on different distributions#9
HyperWinX merged 26 commits intomasterfrom
distro-ci

Conversation

@HyperWinX
Copy link
Member

No description provided.

@mentatbot
Copy link

mentatbot bot commented Apr 5, 2025

I'm getting to work. See my steps and track my cost here.

  • Wake on any new activity.
    I always see new activity while actively working. When paused, I'll only respond when tagged unless this box is checked.

@mentatbot
Copy link

mentatbot bot commented Apr 5, 2025

Overview

I've reviewed the PR which adds CI for building HyperCPU across multiple Linux distributions. This is a great addition that helps ensure cross-platform compatibility!

Positives:

  • Comprehensive testing across 7 distributions with both gcc and clang
  • Fixed several compiler warnings that would break builds on stricter platforms
  • Good error handling with proper set -e in several build scripts
  • Badge integration in the README to show build status

Suggestions:

  1. The workflow currently has continue-on-error: true for all jobs. While this makes sense during initial setup, you might want to consider removing it once you've fixed all distribution-specific issues so that future PRs that break compatibility will fail CI.

  2. For consistency, consider adding set -e to all distribution jobs (it's missing from Arch Linux, Alpine, and the Gentoo jobs)

  3. The README currently only shows badges for Fedora and Debian variants. Consider adding badges for the other distributions as well (Arch, Gentoo, Alpine, Ubuntu).

  4. Since the workflow executes similar commands for each distribution, you might want to consider using a matrix strategy or reusable workflow to reduce duplication.

These are minor suggestions that don't need to block this PR. The implementation as-is looks solid and will be very useful for ensuring the project builds consistently across platforms.

@HyperWinX HyperWinX requested a review from Copilot April 6, 2025 06:10
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 4 out of 9 changed files in this pull request and generated no comments.

Files not reviewed (5)
  • CMakeLists.txt: Language not supported
  • cmake/Variables.cmake: Language not supported
  • src/Emulator/Core/CPU/IO/Simple.cpp: Language not supported
  • test.cpp: Language not supported
  • test/fixtures.hpp: Language not supported

@HyperWinX
Copy link
Member Author

@MentatBot

@mentatbot
Copy link

mentatbot bot commented Apr 6, 2025

Great work on this PR! I see you've addressed several of the suggestions:

  • ✅ Removed continue-on-error: true now that all distribution builds are working correctly
  • ✅ Added set -e to all distribution jobs for consistency
  • ✅ Fixed the GitHub Advanced Security warnings about workflow permissions
  • ✅ Improved branch reference by using github.head_ref instead of github.ref_name

All the CI checks are now passing successfully, which is excellent! The project can now be built reliably across all the targeted distributions.

There are still a couple of minor suggestions that could be addressed in this PR or in a follow-up:

  1. The README only shows badges for Fedora and Debian variants. Adding badges for Arch, Gentoo, Alpine, and Ubuntu would provide a complete status overview.

  2. The workflow has a lot of duplication between jobs. This could potentially be refactored using GitHub Actions matrix strategy or reusable workflows to make it more maintainable.

However, these are purely optimizations and not necessary for the functionality. The PR is looking good and ready to be merged from a technical perspective!

@mentatbot
Copy link

mentatbot bot commented Apr 6, 2025

@HyperWinX

After reviewing the PR again, I believe it's ready to be merged. You've successfully:

  1. Set up CI to test builds across 7 different Linux distributions with both gcc and clang
  2. Fixed compiler warnings/errors across different platforms
  3. Added error handling with set -e in all jobs
  4. Fixed workflow permissions and branch references

All CI checks are passing, which confirms that the project builds correctly on all targeted platforms.

The only minor improvements I suggested (README badges for all distributions and potential workflow optimization) are nice-to-haves that could be addressed in follow-up PRs.

From a technical standpoint, this PR achieves its goal of ensuring cross-platform compatibility and is ready to merge. Great work!

@HyperWinX HyperWinX merged commit 861ac2c into master Apr 6, 2025
11 of 13 checks passed
@HyperWinX HyperWinX deleted the distro-ci branch April 6, 2025 18:49
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.

1 participant