This repository has been archived by the owner. It is now read-only.

Fix for issue #13 - propagate exit status when extension build fails #25

Merged
merged 1 commit into from Oct 18, 2011

Conversation

2 participants
@richmeyers
Contributor

richmeyers commented Oct 12, 2011

Cat of build log clears exit status, causing rpg to think that rpg-build succeeded when in fact it did not.

Attached change causes rpg-build to exit with the same code that extconf.rb exited with, which halts the build as follows:

# rpg install curb
          prepare: calculating dependencies for curb ...
          prepare: 0 of 1 packages already installed and up to date
          install: installing 1 packages
  package-install: curb 0.7.15
            build: curb-0.7.15 ext
checking for curl-config... no
checking for main() in -lcurl... no
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or headers.  Check the mkmf.log file for more
details.  You may need configuration options.

Provided configuration options:
    --with-opt-dir
    --without-opt-dir
    --with-opt-include
    --without-opt-include=${opt-dir}/include
    --with-opt-lib
    --without-opt-lib=${opt-dir}/lib
    --with-make-prog
    --without-make-prog
    --srcdir=.
    --curdir
    --ruby=/usr/local/bin/ruby
    --with-curl-dir
    --without-curl-dir
    --with-curl-include
    --without-curl-include=${curl-dir}/include
    --with-curl-lib
    --without-curl-lib=${curl-dir}/lib
    --with-curllib
    --without-curllib
extconf.rb:18:   Can't find libcurl or curl/curl.h (RuntimeError)

  Try passing --with-curl-dir or --with-curl-lib and --with-curl-include
  options to extconf.
rpg-package-install: extension failed to build
@rtomayko

This comment has been minimized.

Show comment Hide comment
@rtomayko

rtomayko Oct 18, 2011

Owner

Sorry, I missed this somehow. Looks great.

Owner

rtomayko commented Oct 18, 2011

Sorry, I missed this somehow. Looks great.

rtomayko added a commit that referenced this pull request Oct 18, 2011

Merge pull request #25 from richmeyers/extconf-failure-fix
Fix for issue #13 - propagate exit status when extension build fails

@rtomayko rtomayko merged commit f3ceaba into rtomayko:master Oct 18, 2011

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.