Page MenuHomeFreeBSD

Mk/Uses/ Encode more crate build dependencies

Authored by tobik on May 17 2018, 2:44 PM.


  • Add a DEV_WARNING when using libc versions < 0.2.40 to prevent ino64 related issues on 12.0-CURRENT.

Adding @pizzamig for textproc/bat related changes

CC @jbeich because of rP468993

Diff Detail

rP FreeBSD ports repository
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

  • Also sort cargo-crates-licenses output
145 ↗(On Diff #42662)

I've looked at the onig crate code, and I guess


should be more appropriate, but I can be wrong.

119 ↗(On Diff #42662)

bat has no features defined
This line generates a warning, because git2 is a required dependency.
Please remove it.

  • Remove git2 "feature" from bat. Not really sure why I added this.
tobik added inline comments.
145 ↗(On Diff #42662)

Hmm, not sure. The onig_sys build script is like this:

So I don't think RUSTONIG_DYNAMIC_LIBONIG would ever be used when it can find oniguruma >= 6.8.0 on the system.

With RUSTONIG_SYSTEM_LIBONIG bat definitely links with

[111amd64-default-job-03] Installing bat-0.3.0_1...
=>> Checking shared library dependencies
 0x0000000000000001 NEEDED               Shared library: []
 0x0000000000000001 NEEDED               Shared library: []
 0x0000000000000001 NEEDED               Shared library: []
 0x0000000000000001 NEEDED               Shared library: []
 0x0000000000000001 NEEDED               Shared library: []
 0x0000000000000001 NEEDED               Shared library: []

Maybe both should be defined?

145 ↗(On Diff #42662)

IMHO, neither are currently strictly needed, but probably you're right and RUSTONIG_SYSTEM_LIBONIG is the way to go, to be on the safe side.

I've tested onig-sys with zero, one or both variables and the result was always the same, because the system library is preferred, if found, and the static library, that would be the default, is missing from devel/oniguruma, so the dynamic one is used.

tobik marked an inline comment as done.
  • Add comment about RUSTONIG_SYSTEM_LIBONIG
145 ↗(On Diff #42662)

Thanks. I've added a comment to about this.

132–134 ↗(On Diff #42667)

Mmm, the two :M are not the same, if there is a libc.0.1.something, it won't show up in the warning.

CC @0mp because libc warning affects games/genact.

133 ↗(On Diff #42667)

"issues" are mainly crashes but if not they'd be hard to detect. libc crate "supports" 64-bit inodes and absolute kevent(2) timeouts since 0.2.38. rP468993 simply standardized on the latest version to facilitate debugging and pick up other FreeBSD fixes.

134 ↗(On Diff #42667)

12.0-CURRENT will be obsolete in half a year and contributor may confuse libc with base system package. See also existing DEV_WARNING style under Mk/. Maybe try:

.if ${CARGO_CRATES:Mlibc-[0-9]*}
# FreeBSD 12.0 changed ABI: r318736 and r320043
_libc_VER=	${CARGO_CRATES:Mlibc-[0-9]*:C/.*-//}
. if ${_libc_VER:R:R} == 0 && (${_libc_VER:R:E} < 2 || ${_libc_VER:R:E} == 2 && ${_libc_VER:E} < 38)
DEV_WARNING+=	"CARGO_CRATES=libc-0.2.37 or older maybe unstable on FreeBSD 12.0. Consider updating to the latest version."
. endif
.undef _libc_VER
tobik marked 2 inline comments as done.
  • Update libc warning to @jbeich's version
  • Add thrussh-libsodium crate
This revision was not accepted when it landed; it landed in state Needs Review.Jun 14 2018, 9:56 AM
This revision was automatically updated to reflect the committed changes.