Skip to content

Commit

Permalink
eclass/ruby-fakegem.eclass: add options support for extensions
Browse files Browse the repository at this point in the history
Introduce RUBY_FAKEGEM_EXTENSION_OPTIONS to allow setting options for
extensions.

Signed-off-by: Hans de Graaff <[email protected]>
  • Loading branch information
graaff committed Nov 14, 2021
1 parent 2a348f3 commit 04e6a71
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion eclass/ruby-fakegem.eclass
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,13 @@ RUBY_FAKEGEM_BINDIR="${RUBY_FAKEGEM_BINDIR-bin}"
# the configuration script that needs to be run to generate the
# extension.

# @ECLASS-VARIABLE: RUBY_FAKEGEM_EXTENSION_OPTIONS
# @DEFAULT_UNSET
# @DESCRIPTION:
# Additional options that are passed when configuring the
# extension. Some extensions use this to locate paths or turn specific
# parts of the extionsion on or off.

# @ECLASS-VARIABLE: RUBY_FAKEGEM_EXTENSION_LIBDIR
# @DESCRIPTION:
# The lib directory where extensions are copied directly after they have
Expand Down Expand Up @@ -404,7 +411,7 @@ EOF
each_fakegem_configure() {
tc-export PKG_CONFIG
for extension in "${RUBY_FAKEGEM_EXTENSIONS[@]}" ; do
CC=$(tc-getCC) ${RUBY} --disable=did_you_mean -C ${extension%/*} ${extension##*/} || die
CC=$(tc-getCC) ${RUBY} --disable=did_you_mean -C ${extension%/*} ${extension##*/} ${RUBY_FAKEGM_EXTENSION_OPTIONS} || die
done
}

Expand Down

0 comments on commit 04e6a71

Please sign in to comment.