81 Commits

Author SHA1 Message Date
Mike McQuaid
326d3e07e9 fortran_dependency: use gcc instead of gfortran. 2014-05-16 17:42:07 +01:00
Mike McQuaid
efe7fe77a1 python_dependency: don't block pour when :build. 2014-04-04 11:55:36 +01:00
Mike McQuaid
1207ba4f8c python_dependency: only pour with system python.
This is as Python bindings are not build in a way that can have
system or Homebrew Python used interchangeably.
2014-04-03 19:47:15 +01:00
Misty De Meo
0475dbe5cc LD64Dependency: super before setting env proc
Otherwise super will overwrite @env_proc with the default value.
2014-03-23 15:32:34 -07:00
Misty De Meo
497123f7ec LD64Dependency: adjust initializer signature
The method signature of Dependency changed in
1fdf69b90382c43493a5f62f0020729289db6c70, however LD64Dependency was
missed in the update. This resulted in failures in merge_repeats(),
which creates many dependency objects using all three arguments.
2014-03-22 18:50:54 -07:00
Mike McQuaid
8dcadc54d2 python_dependency: no brewed python for bottles 2014-03-18 12:08:12 +00:00
Mike McQuaid
afec712a86 python_dependency: move bottle check into method. 2014-03-14 18:21:29 +00:00
Mike McQuaid
5b6d872459 python_dependency: always bottle with brew Python. 2014-03-13 10:05:20 +00:00
Mike McQuaid
c594053449 python_dependency: fixes, features, cleanup.
- PythonDependency now implies Python 2.7
- PythonDependency now uses brewed Python for bottling
- Use double-quotes everywhere

Closes Homebrew/homebrew#27112.
2014-03-12 13:56:41 +00:00
Mike McQuaid
686f829f2f language_module_dependency: handle nil import_name 2014-03-09 17:24:50 +00:00
Jack Nagel
8bfcdf0bd8 Remove special X11 proxy deps 2014-03-05 20:45:44 -06:00
Mike McQuaid
f42f4e45c1 python_dependency: only set PYTHONPATH for system. 2014-02-10 18:49:26 +00:00
Jack Nagel
15db61f25a X11Dependency: style 2014-02-09 14:23:56 -05:00
Jack Nagel
f16003f58c X11Dependency: return nil instead of raising in #<=>
Returning nil is in the contract of the Comparable module, and a future
version of Ruby will no longer hide this error.
2014-02-09 14:23:56 -05:00
Mike McQuaid
a42ac924dd language_module_dependency: don't use build_env.
This is so a e.g. brewed Python's modules can be found by superenv.

References Homebrew/homebrew#26229.
Closes Homebrew/homebrew#26197.
2014-01-30 09:51:42 +01:00
Mike McQuaid
ed53bb333b python_dependency: cleanup and fix build env.
* Only set PYTHONPATH for Python 2.
* Set the Python binary for superenv.

References Homebrew/homebrew#24842.
Closes Homebrew/homebrew#26197.
Closes Homebrew/homebrew#26216.
Closes Homebrew/homebrew#26218.
Closes Homebrew/homebrew#26228.
2014-01-29 17:49:57 +01:00
Mike McQuaid
689be66203 python_dependency: cleanup, fix satisfy.
Closes Homebrew/homebrew#26067.
2014-01-20 23:30:32 -08:00
Mike McQuaid
28143fb653 PythonDependency: massive refactoring.
Closes Homebrew/homebrew#24842.
2014-01-20 15:42:52 -08:00
Jack Nagel
92ac63fd94 LanguageModuleDependency: remove code that only worked by accident
The array elements here are individual arguments to exec, not a string
to pass to the shell; this only appeared to work. In reality, `opam
list` accepts "|" as valid argument, and the command works fine without
grepping the output.
2014-01-11 19:37:19 -06:00
Mike McQuaid
4c2e7b1659 Update docs, comment mxcl/homebrew refs. 2013-12-14 18:18:35 +00:00
MinRK
cb7f158663 safer check for sys.executable in sitecustomize.py
make sure it doesn't actually point to something else

since sitecustomize.py is put in a location found by pypy,
it breaks pypy by setting sys.executable to a path that is definitely wrong,
and may not even exist.

Closes Homebrew/homebrew#24581.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2013-11-25 20:48:41 -08:00
Jack Nagel
4943a81373 Python might not be up-to-date, so use opt_prefix
Fixes Homebrew/homebrew#24456.
2013-11-18 17:08:04 -06:00
Adam Vandenberg
7df136cd50 grammar edits 2013-11-13 20:23:27 -08:00
Mike McQuaid
bdbaf61304 python_dependency: fix includes location on 10.9.
Fixes Homebrew/homebrew#23837.
Fixes Homebrew/homebrew#23866.
2013-11-01 11:19:23 -07:00
Jack Nagel
3df31557c8 Avoid the need to defensively flatten tags array 2013-10-15 13:26:23 -05:00
Mike McQuaid
315c7a1212 Rename PythonInstalled to PythonDependency.
Make it more consistent with other requirements.
2013-09-14 12:21:49 +01:00
Mike McQuaid
a16394fde8 MinimumMacOSRequirement: rename file.
Should be using minimum_mac_os_requirement.rb
2013-09-14 12:21:49 +01:00
Samuel John
5515fda59a PythonInstalled: Allow formulae to set/append PYTHONPATH
Improve robustness of `PYTHONPATH` by first unsetting it (during
`satisfy`) so that the `PythonInstalled` can get the `python.version`
and so forth and then, after that, setting the `PYTHONPATH` to our
`global_site_packages`.
In the `python_helper` we append to the `PYTHONPATH` so if that var has
been set in a formula, it is respected.
Brew audit does no longer complain about setting the
`ENV['PYTHONPATH']`.
2013-09-03 10:46:06 +02:00
Samuel John
dbaac79f17 PythonInstalled: Adding a private_site_packages
that live in the `libexec` dir of a `Cellar`.
2013-09-03 10:41:54 +02:00
Samuel John
2e2e46b5b4 PythonInstalled, name includes modules
If `depends_on :python => ['modulename', :optional]` then the generated
option is now `--with-python-modulename`, so that it is possible to
actually make depending on python modules optional.
Further, `brew options` becomes more meaningful.
2013-08-27 09:48:12 +02:00
Samuel John
c4d8917f3f PythonInstalled: Unset PYTHONPATH for satisfied?
When a formula `depends_on :python` *and* `depends_on :python3`
the `modify_build_environment` method sets the PYTHONPATH
and the Python 3.x requirement then fails because it finds
the sitecustomize.py from Python 2.x in the PYTHONPATH.
2013-08-23 20:26:47 +02:00
Jack Nagel
4a3dac82ef Use ENV.prepend_path 2013-08-19 17:21:13 -05:00
Jack Nagel
ea8f51256b Use ENV.append_path 2013-08-19 17:21:13 -05:00
Jack Nagel
1ffd40821a which in requirements always uses ORIGINAL_PATHS now
Fixes Homebrew/homebrew#22002.
2013-08-19 13:54:09 -05:00
Amos Wenger
52ace99f14 Use File::PATH_SEPARATOR globally instead of ':'
On Unix, the path separator is ':', whereas on Windows,
it is ';'. This is the first of a series of patch to bring
macbrew's and winbrew's codebases closer together.

The main places the magic constant ':' was being used were:
  - the $PATH environment variable
  - CMAKE-related environment variables
  - pkg-config related environment variables

Closes Homebrew/homebrew#21921.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2013-08-19 13:35:44 -05:00
Samuel John
a7a35efff4 Unlinked brewed python -> use system python
Up to now a brewed Python, even if not linked, was preferred over
and external Python, so that you had to completely `brew rm python`
to have a formula link against external (mostly system) Python.

From now on it is okay to `brew unlink python`.
2013-08-15 02:03:55 +02:00
Jack Nagel
d77240a98c Iterate over these directly rather than mapping first 2013-08-14 13:02:50 -05:00
Jack Nagel
603d8f9d4d Return value of modify_build_environment is unimportant 2013-08-14 13:01:35 -05:00
Jack Nagel
f8c34b5dc1 Reverse conditional 2013-08-14 12:46:37 -05:00
Jack Nagel
3857f83e9c Collapse to one-liner 2013-08-14 12:46:12 -05:00
Jack Nagel
3d39a57118 No need to map, all? takes a block 2013-08-14 12:45:54 -05:00
Jack Nagel
4d2188cc90 Add missing false 2013-08-14 12:41:52 -05:00
Jack Nagel
5561d3d09c Remove stray space 2013-08-14 12:41:15 -05:00
Jack Nagel
23fbe23426 Allow specifying a custom PATH for which method
Closes Homebrew/homebrew#21794.
2013-08-10 19:01:50 -05:00
Samuel John
a73012def4 Python: Exit if PYTHONPATH is wrong
In our sitecustomize.py we instruct python to exit with an error message
if the PYTHONPATH is pointing to a wrong homebrew site-packages dir.
With wrong meaning another major python version.

If you set the PYTHONPATH to include
    $(brew --prefix)/lib/python2.7/site-packages
and start python3, it may pick up modules from there, wich can result
in errors for non pure python modules (such as PyQt).
2013-08-08 11:54:42 +02:00
Samuel John
c968f8302f For brewed python, make sure to unset the PYTHONPATH
during building of python software inside of a `python do … end` block.
2013-08-08 11:50:46 +02:00
Adam Vandenberg
73547fc750 Remove ARCHFLAGS fixme from Python dependency
This will be handled by env/superenv, not Python.
2013-08-03 10:28:57 -07:00
Jack Nagel
6090b9b2bf Silence warnings 2013-07-22 11:41:47 -05:00
Jack Nagel
e33cdb2f8b Fix python dependency hash equality
eql? should not depend on the hash value as hash values of uneql objects
can collide, but eql values may only collide for objects that are
actually eql.

Further, python dependencies are uniquely identified by the combination
of the name and imports attributes, so there is no reason to involved
the expensive binary computation for simple equality checks.

Fixes Homebrew/homebrew#20840.
2013-07-22 11:41:46 -05:00
Jack Nagel
b0138b9c9b Remove redundant reader method 2013-07-22 11:41:46 -05:00