-
Notifications
You must be signed in to change notification settings - Fork 256
Add new wrap for tinycdb #2277
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Add new wrap for tinycdb #2277
Conversation
3e15fe9
to
40c7b3a
Compare
No idea why the macOS / msys2 and Visual Studio CI pipelines are trying to run, given that
for the module. I can update this if given some guidance (I just want the module for Linux, I haven’t – and can’t – test it on other platforms), but I’m done with trying to appease the CI for now, sorry. |
) | ||
|
||
if host_machine.system() != 'linux' | ||
error('tinycdb is not tested on this platform.') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this mean that the source code isn't designed to work on non Linux platforms (for example it uses Linux kernel APIs) or just that this wrap doesn't implement it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The source code has no dependencies other than libc, but uses unistd.h
. The comment in the meson.build
was meant to convey that I have not tested tinycdb on platforms other than my Fedora box.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
macOS homebrew has bottles for tinycdb -- depending on POSIX headers just means it needs a unix system. So macOS should be fine. I agree that there's no reason to bend over backwards and port this software over to the Win32 API.
It's not a comment if it's a runtime error() function call.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd also suggest implementing a test() function, probably via a python script that runs the tests.sh script in the upstream source code and then compares the output to the tests.ok
file.
This will allow you to have some confidence that it runs on systems other than Fedora. :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not interested in spending any time on testing this for non-Linux systems, sorry. I am happy to do whatever small changes are required to get it to build on Linux CI. I submitted it upstream because it could be useful to others, but if there’s a higher bar for things entering wrapdb other than “it builds with this meson.build
on at least a Linux CI system” then fair enough. If so I’ll just keep the .wrap
file locally in my project’s subprojects dir and close this PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, let me clarify. I think adding a wrap for Linux is good to test on Linux (in the wrapdb CI).
The macOS point is entirely separate. You need do no work to "get it to build" there. The first iteration of this PR worked on macOS just fine, but failed on Windows: https://github.com/mesonbuild/wrapdb/actions/runs/16374154384
So, don't bother:
spending any time on testing this for non-Linux systems
but simply
blindly assume it works on macOS.
error('tinycdb is not tested on this platform.') | |
if host_machine.system() in ['windows', 'cygwin'] | |
error('tinycdb is not supported on non-POSIX plarforms.') |
That's the only change needed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the patient explanation. Let’s see if the latest push works (Alpine aside).
The alpine tests are failing because @jirutka's action is 404'ing. Perhaps we should just disable Alpine tests for now, |
The problem is that gitlab.alpinelinux.org is unavailable, there’s some outage. @Ikke, could you kindly shed some light on the reason why Alpine’s GitLab is inaccessible for multiple hours, for the second time in this week? |
Alpine’s GitLab is back online, so the jobs should pass now. |
tinycdb = static_library( | ||
'cdb', | ||
lib_srcs, | ||
cpp_args: ['-D_FILE_OFFSET_BITS=64'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Meson defines this automatically.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was set explicitly in the Makefile
which the meson.build
is based off, so I think it would be clearer to keep it explicit in the meson.build
From https://www.corpit.ru/mjt/tinycdb.html Signed-off-by: Philip Withnall <[email protected]>
Something is causing heavy long-running git processes to be spawned that overload the server. Because I was traveling and most of the time only had access to a tiny screen, all I was able to do is try to stabilize things again whenever I had opportunity (others looked at it as well but could not do a lot more). |
From https://www.corpit.ru/mjt/tinycdb.html