- 
                Notifications
    
You must be signed in to change notification settings  - Fork 87
 
Closed
Labels
Description
Describe the bug
rules_haskell in GHC bindist mode (not Nix shell) requires the python package on Ubuntu which provides Python 2.
To Reproduce
Try to run rules_haskell test suite on Ubuntu image without Python 2 installed. See https://buildkite.com/tweag-1/rules-haskell/builds/667#a3798e34-7be3-433f-bfa3-0aca1b0a303f/36-2757.
<no location info>: error:
--
  | Warning: Couldn't figure out C compiler information!
  | Make sure you're using GNU gcc, or clang
  | /usr/bin/env: ‘python’: No such file or directory
  | `cc_wrapper-python' failed in phase `Assembler'. (Exit code: 127)
Expected behavior
Python 3 alone (python3 on Ubuntu) should be sufficient.
Environment
- OS name + version: Ubuntu 19.04
 - Bazel version: 1.1
 - Version of the rules: 3659373
 
Additional context
The cc_wrapper script that raises the error is a py_binary target. The source file specifies #!/usr/bin/env python3, however, it seems that Bazel generates a Python script requiring /usr/bin/env python anyway.
cc @flokli