Re-work native engine version.

Review Request #4367 - Created Nov. 11, 2016 and submitted

Information
John Sirois
pants
jsirois/issues/4035
4034, 4035, 4046
9a1c66f...
Reviewers
pants-reviews
kwlzn, nhoward_tw, stuhood
This switches the `Native` subsystem to load the proper native engine
library version from a resource file that is, in-turn, auto-managed by
the pants script itself ensuring that pants, both in-repo and as a
released package (pex or sdist or wheel), will always ask for the exact
native engine library version it was built and tested with.

A follow-up change will ensure we release a native engine library to
bintray for all packaged releases, fulfilling the released pants package
portion of the contract.

 build-support/bootstrap_native                          | 21 ++++++++++++++++-----
 build-support/common.sh                                 |  2 +-
 pants                                                   |  1 -
 src/python/pants/engine/subsystem/BUILD                 | 14 +++++++++++---
 src/python/pants/engine/subsystem/README.md             |  8 ++++++++
 src/python/pants/engine/subsystem/native.py             | 11 ++++++++---
 src/python/pants/engine/subsystem/native_engine_version |  1 +
 7 files changed, 45 insertions(+), 13 deletions(-)

Locally exercised both loose and packaged default version:

$ ./pants options --scope=native-engine --name=version
native-engine.version = 83a37939cc48722fc930bd4493aec3b48bef2ac0 (from HARDCODED)

$ src/python/pants/bin:pants_local_binary
$ ./dist/pants_local_binary.pex options --scope=native-engine --name=version
native-engine.version = 83a37939cc48722fc930bd4493aec3b48bef2ac0 (from HARDCODED)

CI went green here
https://travis-ci.org/pantsbuild/pants/builds/175187641

John Sirois
John Sirois
Kris Wilson
John Sirois
John Sirois
John Sirois
John Sirois
Review request changed

Status: Closed (submitted)

Change Summary:

Now on master:

git log -1 origin/master
commit cede1ec82960eadcca8a9bdf2744797643513aa4
Author: John Sirois <john.sirois@gmail.com>
Date:   Fri Nov 11 14:05:57 2016 -0800

    Re-work native engine version.
    
    This switches the `Native` subsystem to load the proper native engine
    library version from a resource file that is, in-turn, auto-managed by
    the pants script itself ensuring that pants, both in-repo and as a
    released package (pex or sdist or wheel), will always ask for the exact
    native engine library version it was built and tested with.
    
    A follow-up change will ensure we release a native engine library to
    bintray for all packaged releases, fulfilling the released pants package
    portion of the contract.
    
    Testing Done:
    Locally exercised both loose and packaged default version:
    ```
    $ ./pants options --scope=native-engine --name=version
    native-engine.version = 83a37939cc48722fc930bd4493aec3b48bef2ac0 (from HARDCODED)
    
    $ src/python/pants/bin:pants_local_binary
    $ ./dist/pants_local_binary.pex options --scope=native-engine --name=version
    native-engine.version = 83a37939cc48722fc930bd4493aec3b48bef2ac0 (from HARDCODED)
    
    ```
    
    CI went green here
      https://travis-ci.org/pantsbuild/pants/builds/175187641
    
    Bugs closed: 4034, 4035, 4046
    
    Reviewed at https://rbcommons.com/s/twitter/r/4367/
Loading...