Codebase list facter / 8fd1db8
Make libfacter.so available to Ruby libfacter.so also serves as a Ruby native extension. Make it available to all supported Ruby versions by symlinking it under Ruby's vendorarchdir. This also requires Build-Depending on ruby-all-dev. Apollon Oikonomopoulos 6 years ago
5 changed file(s) with 44 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
2626 libyaml-cpp-dev,
2727 libssl-dev,
2828 rapidjson-dev,
29 ruby-dev,
29 ruby-all-dev,
3030 Standards-Version: 4.1.3
3131 Vcs-Git: https://salsa.debian.org/puppet-team/facter.git
3232 Vcs-Browser: https://salsa.debian.org/puppet-team/facter
0 #!/usr/bin/ruby
1
2 require 'ruby_debian_dev'
3
4 RubyDebianDev::RUBY_INTERPRETERS.each do |interp, data|
5 puts %x{#{data[:binary]} -rrbconfig -e 'puts RbConfig::CONFIG["vendorarchdir"]'}
6 end
0 Author: Apollon Oikonomopoulos <apoikos@debian.org>
1 Description: Use libruby directly from Ruby's $LOAD_PATH
2 Last-Update: 2018-03-02
3 Forwarded: no (Debian-specific)
4 --- a/lib/facter.rb.in
5 +++ b/lib/facter.rb.in
6 @@ -27,17 +27,7 @@
7 else
8 # Simply require libfacter.so; this will define all of the Facter API
9 begin
10 - facter_dir = ENV['FACTERDIR'] || File.join(File.expand_path("#{File.dirname(__FILE__)}"), '${LIBFACTER_INSTALL_RELATIVE}')
11 - #
12 - # This is a cmake pre-processor check. On *nix it will end up '' == '1'
13 - # On windows, where we want the changes it will be '1' == '1'
14 - #
15 - # Facter requires the extra inclusion of puppet/bin as the libfacter.so
16 - # lib requires libraries and executables from that directory
17 - if '${WIN32}' == '1'
18 - ENV['PATH'] = "#{File.join(facter_dir, 'bin')}#{File::PATH_SEPARATOR}#{File.join(facter_dir, '../puppet/bin')}#{File::PATH_SEPARATOR}#{ENV['PATH']}"
19 - end
20 - require "#{facter_dir}/${LIBFACTER_INSTALL_DESTINATION}/libfacter.so"
21 + require "libfacter.so"
22 rescue LoadError
23 raise LoadError.new('libfacter was not found. Please make sure it was installed to the expected location.')
24 end
00 use-shared-cpp-hocon.patch
1 ruby-fix-library-name.patch
00 #!/usr/bin/make -f
11 # -*- makefile -*-
2
3 include /usr/share/dpkg/pkg-info.mk
24
35 export DEB_BUILD_MAINT_OPTIONS = hardening=+all
46 export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed
810
911 override_dh_missing:
1012 dh_missing --fail-missing
13
14 override_dh_link:
15 dh_link
16 for target in $$($(CURDIR)/debian/list-ruby-dirs); do \
17 dh_link -pfacter \
18 /usr/lib/$(DEB_HOST_MULTIARCH)/libfacter.so.$(DEB_VERSION_UPSTREAM) \
19 "$${target}/libfacter.so"; \
20 done