Commit Graph
22 Commits
Author SHA1 Message Date
Samuel John 0b50110107 Python 2.x and 3.x support
New `depends_on :python` Dependency.
New `depends_on :python3` Dependency.

To avoid having multiple formulae with endings -py2 and -py3,
we will handle support for different pythons (2.x vs. 3.x)
in the same formula.
Further brewed vs. external python will be transparently supported.

The formula also gets a new object `python`, which is false if
no Python is available or the user has disabled it. Otherwise
it is defined and provides several support methods:

python.site_packages # the site-packages in the formula's Cellar
python.global_site_packages
python.binary # the full path to the python binary
python.prefix
python.version
python.version.major
python.version.minor
python.xy # => e.g. "python2.7"
python.incdir # includes of python
python.libdir # the python dylib library
python.pkg_config_path # used internally by brew
python.from_osx?
python.framework?
python.universal?
python.pypy?
python.standard_caveats # Text to set PYTHONPATH for python.from_osx?
python.if3then3 # => "" for 2.x and to "3" for 3.x.

Further, to avoid code duplication, `python` takes an optional
block that is run twice if the formula defines depends_on
:python AND :python3.

python do
  system python, 'setup.py', "--prefix=#{prefix}"
end

Read more in the Homebrew wiki.
2013-06-03 17:29:43 +02:00
Adam Vandenberg df081577ad wxmac: style nits 2013-01-27 14:54:50 -08:00
Jack Nagel 3ad7174f7d Use new requirement syntax 2013-01-21 17:36:34 -06:00
Jack Nagel 43f2bfaafc Use fatal DSL method in requirements 2013-01-18 19:30:43 -06:00
Samuel John 9e4d2ca3ed wxmac: Multiversion support.
Some popular python packages expect to "import wxversion", which
is only available on a multiversion build.

A multiversion of wxPython should have no negative side effects.
A usual `import wx` still works.

Closes #16515.

Signed-off-by: Charlie Sharpsteen <source@sharpsteen.net>
2012-12-11 08:38:33 -08:00
Adam Vandenberg 3ff7c481bb wxmac: use new dsl 2012-08-23 15:14:08 -07:00
samueljohn 1de2b52195 wxmac: 2.9.4
- patch no longer needed
- blacklist.rb: Removed version number because we forget to update it too often.

Closes #13997.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2012-08-06 10:33:54 -07:00
Adam Vandenberg 1884514687 wxmac style updates 2012-07-22 15:03:46 -07:00
samueljohn 6765647623 wxmac 2.9
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2012-07-22 14:49:48 -07:00
Trevor Wennblom 5dcb5489d9 wxmac: use standard C++ string classes
http://groups.google.com/group/wx-dev/browse_thread/thread/07aaa5303b379306

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2012-06-27 11:16:23 -07:00
Jack Nagel 417d788070 Shore up a number of shell quoting issues
When interpolating in strings passed to Formula#system, it should be
done in such a way that if any interpolated variables contain spaces,
they are either (a) passed as part of a list or (b) protected by quotes
if they are part of a long string (which is subject to shell expansion).
Otherwise, they will be split on the space when expanded by the shell
and passed as multiple arguments to whatever process is being executed.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-05-15 14:03:11 -05:00
Adam Vandenberg d3f3554299 Use "cd" instead of "Dir.chdir"
* And "mkdir" isntead of "Dir.mkdir"
* And "Dir[]" instead of "Dir.glob"
* Also style fixes and nitpicks
2012-02-24 21:35:50 -08:00
Charlie Sharpsteen cf4509fd9c wxMac: Fix build flags
Use the standard `ENV.m32` to force a 32-bit build now that Homebrew's
environment tools can work with Objective C flags.

Only specify `-arch` flags when building Python modules---this prevents Python
from trying to build for more architectures than it should.

Fixes #10348.
2012-02-22 11:50:14 -08:00
samueljohn c15bf39206 wxmac: Add 2.9.x as --devel option
- 64bit and cocoa is only possible in the 2.9 series.
- Using the bundle wxPython+wxWidgets for 2.9.x.
- Better caveats telling about all issues based on the actual options to guide the users with options/problems.
- Building gizmos, sec and ogl only for 2.8 (because 2.9 does not have these subduers)
- Python bindings for 2.8 are now built with MacOS 10.6 sdk on Lion explicitly for i386. This fixes the error of "Cursor" not found during build time in current wxmac formula.
- Added head for wxPython (may be of use later on)
- Set right home pages.
- Removed --system-python. Not needed, since the policy is to take whichever python is upfront in the path.
- Fixed bug that "gizmos", "stc" and "ogl" were not built because "$c" is not a variable expansion expression in ruby. "#{c}" was meant.

Closes #8639.
Closes #10149.

Signed-off-by: Charlie Sharpsteen <source@sharpsteen.net>
2012-02-16 14:47:25 -08:00
Hiroaki Nakamura 5e82c4b35a wxmac 2.8.12
* also build contrib modules needed by wxErlang

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2012-01-27 23:33:20 -08:00
BEN ENGLISCH df2870641b wxmac: fix building for Lion
Closes #8378.

Signed-off-by: Misty De Meo <mistydemeo@gmail.com>
2011-12-13 23:03:00 -06:00
Christopher Currie 30342571b5 Add Python bindings for wxmac
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-06-08 20:08:30 -07:00
Eric Kow fbb968543d wxmac: enable unicode support explicitly
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-05-19 07:59:43 -07:00
Adam Vandenberg 0476235ce0 Use ruby style for inheritance. 2011-03-12 11:55:09 -08:00
Adam Vandenberg dd2adc39af Update wxWidgets to 2.8.11 and add caveats. 2010-04-26 11:21:54 -07:00
Adam Vandenberg da3d404475 wxWidgets - use bz2 download. 2009-11-13 20:30:58 -08:00
Kieran Pilkington 2ae8c43a26 wxWidgets for Mac
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2009-11-13 20:30:58 -08:00