Page MenuHomeFreeBSD

new port: sysutils/facter
ClosedPublic

Authored by mmoll on Sep 6 2015, 9:30 PM.

Details

Summary

This is a port of facter 3, which is now written in C++. It does install it's ruby "connector" into /usr/local/lib/ruby/vendor_ruby, I'm unsure if that's OK. Also, I didn't get it to compile on 9.x despite specifying C++11.

Diff Detail

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

Event Timeline

mmoll updated this revision to Diff 8534.Sep 6 2015, 9:30 PM
mmoll retitled this revision from to new port: sysutils/facter.
mmoll updated this object.
mmoll edited the test plan for this revision. (Show Details)
mmoll added reviewers: swills, robak, sunpoet.
mat added a subscriber: mat.Sep 6 2015, 9:50 PM

It doesn't really matter where it installs its stuff, as long as ruby -rfacter works :-)

What breaks on FreeBSD 9 ? (I'm by no mean a C++ expert, just wondering.)

mat added inline comments.Sep 6 2015, 9:51 PM
sysutils/facter/Makefile
22 ↗(On Diff #8534)

Can it build if rubygem-facter is installed ?
If it's just an install conflict, do CONFLICTS_INSTALL=blah

mmoll added a comment.Sep 6 2015, 9:54 PM

On FreeBSD 9.3 (poudriere jail on 10.2):

[  6%] Building CXX object lib/CMakeFiles/libfactersrc.dir/src/facts/collection.cc.o
cd /wrkdirs/usr/ports/sysutils/facter/work/facter-3.0.2/lib && /usr/local/bin/g++48   -DBOOST_ALL_DYN_LINK -DBOOST_LOG_WITHOUT_WCHAR_T -DLEATHERMAN_LOGGING_NAMESPACE=\"puppetlabs.facter\" -DUSE_OPENSSL -DUSE_POSIX_FUNCTIONS -DUSE_YAMLCPP -O2 -pipe -fstack-protector -Wl,-rpath=/usr/local/lib/gcc48 -fno-strict-aliasing -Wl,-rpath=/usr/local/lib/gcc48 -Wno-maybe-uninitialized -std=c++11 -Wall -Werror -Wno-unused-parameter -Wno-unused-local-typedefs -Wno-unknown-pragmas -Wno-missing-field-initializers -Wextra -O2 -pipe -fstack-protector -Wl,-rpath=/usr/local/lib/gcc48 -fno-strict-aliasing -Wl,-rpath=/usr/local/lib/gcc48 -fPIC -I/wrkdirs/usr/ports/sysutils/facter/work/facter-3.0.2/lib/inc -I/wrkdirs/usr/ports/sysutils/facter/work/facter-3.0.2/vendor/rapidjson-0.11/include -I/usr/local/include -I/wrkdirs/usr/ports/sysutils/facter/work/facter-3.0.2/vendor/leatherman/vendor/boost-nowide -I/wrkdirs/usr/ports/sysutils/facter/work/facter-3.0.2/vendor/leatherman/locale/inc -I/wrkdirs/usr/ports/sysutils/facter/work/facter-3.0.2/vendor/leatherman/logging/inc     -Winvalid-pch -include "/wrkdirs/usr/ports/sysutils/facter/work/facter-3.0.2/lib/cotire/libfactersrc_CXX_prefix.hxx" -o CMakeFiles/libfactersrc.dir/src/facts/collection.cc.o -c /wrkdirs/usr/ports/sysutils/facter/work/facter-3.0.2/lib/src/facts/collection.cc
/wrkdirs/usr/ports/sysutils/facter/work/facter-3.0.2/lib/src/facts/collection.cc: In member function 'const facter::facts::value* facter::facts::collection::lookup(const facter::facts::value*, const string&)':
/wrkdirs/usr/ports/sysutils/facter/work/facter-3.0.2/lib/src/facts/collection.cc:389:34: error: 'stoi' was not declared in this scope
                 index = stoi(name);
                                  ^
*** [lib/CMakeFiles/libfactersrc.dir/src/facts/collection.cc.o] Error code 1
mmoll marked an inline comment as done.Sep 6 2015, 9:58 PM
mmoll added inline comments.
sysutils/facter/Makefile
22 ↗(On Diff #8534)

it can :)

mmoll marked an inline comment as done.Sep 7 2015, 3:32 PM

For the record, I'm getting the same compiler error with 10.2 on sparc64 (which has gcc 4.2 in base and thus uses lang/gcc)

mmoll updated this revision to Diff 8636.Sep 10 2015, 9:48 AM

copied libc++ check from editors/libreoffice

mmoll updated this revision to Diff 8637.Sep 10 2015, 11:55 AM

address comments by marino@

mat added inline comments.Sep 10 2015, 12:49 PM
sysutils/facter/Makefile
26 ↗(On Diff #8637)

Have you tested that ?
You need to include, bsd.ports.pre.mk before you can use COMPILER_FEATURES.
And then, you can't use BROKEN_FreeBSD anyway.

mmoll updated this revision to Diff 8640.Sep 10 2015, 2:36 PM

fix Makefile

mmoll marked an inline comment as done.Sep 10 2015, 2:43 PM
mmoll added inline comments.
sysutils/facter/Makefile
26 ↗(On Diff #8637)

fixed now.

mat added inline comments.Sep 10 2015, 11:51 PM
sysutils/facter/Makefile
28–29 ↗(On Diff #8640)

well, those two could be collapsed into one, otherwise, looks good.

This revision was automatically updated to reflect the committed changes.
mmoll marked an inline comment as done.