[3/3] Add GitHub Actions CI with build and test automation#282
[3/3] Add GitHub Actions CI with build and test automation#282irodushka merged 1 commit intoFirebirdSQL:masterfrom
Conversation
|
Hi @fdcastel Let's start our conversation again) What is |
It’s essentially a build script -- similar to a makefile -- but written in PowerShell (using tools like Invoke-Build). We use a similar script system for Firebird Docker images.
In many cases, a shell script is simpler to read and maintain. It also allows you to reuse existing PowerShell modules (like PSFirebird or the above cited Invoke-Build) instead of reimplementing functionality from scratch.
Correct.
Because -- aside from the benefits mentioned above -- PowerShell has been running on Linux for more than 10 years now 😉 |
ca590f0 to
2fc2359
Compare
Add a unified build-and-test workflow using PowerShell (Invoke-Build) and PSFirebird for cross-platform CI on Windows and Linux: - Build the driver with CMake (Release, x64) - Download and configure Firebird 5.0.2 via PSFirebird module - Create test databases (UTF-8 and ISO-8859-1) - Register the ODBC driver - Run the full test suite with three charset configurations Also: - Fix processorArchitecture in DLL manifest from X86 to wildcard (*) so the driver loads correctly on x64 and ARM64 builds - Remove linux.yml (superseded by build-and-test.yml) - Remove rpi_arm64.yml (niche; Linux CI covers this) - Clean up temporary branch names from msbuild workflow triggers
|
Improved the README section on building the project. |
|
@fdcastel So if these ps1 scripts should be used for CI only, it's no problem here) and yes, I'm an oldschool geezer, you've guessed right!)) Just the last (I hope) question - what about the installers? We have the InnoSetup for MSBuild now - I agree it's ugly and buggy and have a big problem with Windows antivirus, but it's better than nothing. As far as I remember you mentioned some other more modern approarch for the installer software, so where is it and when should we except it to appear?) |
Sure, it’s optional. Feel free to stick with whatever BASH flavor makes your terminal feel like home 😉
Ah, yes, the WiX installer! It’s included in vNext. It didn't show up here because I was simply following the plan. But if you’d like it included in this PR (or any other feature from the other fork), I can bring it over. No problem! Just let me know. |
Np to merge it as is, and I gonna do it now. |
|
https://github.com/FirebirdSQL/firebird-odbc-driver/actions/runs/24034920090/job/70092000216 |
Great! 🎉 This closes our initial plan from #275. Now, please, investigate which parts from #283 should we migrate next?. It would probably make sense to begin with the most critical issues listed in section 1 of this document. They’re roughly organized in the same order I’ve been tackling the tasks. (suggestion: You may open new issues here on GitHub an assign them to me, if you prefer)
Working on it. (curiously, this was one change that ended not being in the plan) |
@irodushka I’ll look into it. GitHub enforces a low rate limit for unauthenticated requests. |
|
I suppose we should add smth like to P.S. Nope. The error occures after build while executing |
Almost that. Yes, we do need to set it. But as an If this env var is defined, the PSFirebird code that makes the GitHub request will automatically use it. I’ll update the PSFirebird documentation to alert to this fact. |
|
Fixed in #285. |
|
The prev issue is fixed, true. libOdbcFb.so looks big, maybe it's not stripped?.. |
|
Lets continue this on #286 |
This is the third and last part of planned PRs aimed at improving the project infrastructure, as outlined in the plan discussed in PR #275.
Summary
Add a unified Build and Test workflow that automates building the driver and running the full test suite on every push and PR. This replaces the existing Linux-only workflow and the Raspberry Pi workflow with a cross-platform CI pipeline that uses PowerShell (Invoke-Build) and PSFirebird for consistent orchestration on both Windows and Linux.
What this PR does
New:
build-and-test.ymlworkflowNew:
firebird-odbc-driver.build.ps1(Invoke-Build script)Cross-platform build script with tasks:
clean,build,build-test-databases,install,uninstall,test. Works identically on Windows and Linux. Can be used locally:New:
install-prerequisites.ps1Installs required PowerShell modules (PSFirebird, InvokeBuild).
Fix:
FirebirdODBC.dll.manifestChanged
processorArchitecturefromX86to*(wildcard). The old value caused DLL loading failures (system error 193) on x64 and ARM64 builds because the embedded manifest requested x86 Common Controls, triggering a SxS architecture mismatch.Removed workflows
build-and-test.ymlKept workflows
Test results
Both Windows and Linux CI jobs pass with identical results:
gtest_discover_tests)Local and CI results match.