regexp-examples icon indicating copy to clipboard operation
regexp-examples copied to clipboard

1.6.0 no longer is a pure ruby install

Open cabo opened this issue 1 year ago • 4 comments

Some of the users of the cddl tool are using a CI environment that doesn't provide for native builds. Since 1.6.0, regexp-examples needs regexp_property_values, which appears to need a native build. This means the CI chains now fail. Is there a way to use regexp-examples without requiring a native build?

cabo avatar Jun 17 '24 11:06 cabo

As commented here:

regexp_property_values ... includes C-extensions. The extensions are optional, and the fallback code has successfully been used in some non-C-Ruby environments, but I wouldn't vouch for them to work in every exotic setup

I didn't test this library on non-native builds, so haven't experienced an error. The mentioned dependency claims to have optional extensions, and I see the key code to support it is here. Maybe the issue would be better raised in that project, if you have an installation error?

Barring that, you may have to stick with v1.5.x of this gem.

tom-lord avatar Jun 25 '24 12:06 tom-lord

I didn't test this library on non-native builds, so haven't experienced an error. The mentioned dependency claims to have optional extensions, and I see the key code to support it is here. Maybe the issue would be better raised in that project, if you have an installation error?

The code is great; the problem is that bundler and gem do not know that this is a conditional dependency. So you cannot gem install or bundle install 1.6.0 without a compiler. The question is how to create such a conditional dependency.

cabo avatar Jun 25 '24 12:06 cabo

@cabo try this maybe https://github.com/wycats/bundler/issues/143#issuecomment-1749433112

Nakilon avatar Nov 26 '25 13:11 Nakilon

Since it's not resolved in the bundler bug tracker, I suppose regexp-examples should have that dependency not being in the gemspec but be only recommended via... README or the thing that prints after you install the gem, you know? It's done via different gemspec directive.

Nakilon avatar Nov 26 '25 13:11 Nakilon