Commit Graph

12 Commits (04248c273e0eaeb7f4e62a6e184f0b2a26078ab1)

Author SHA1 Message Date
Samuel John f6e80bdea2 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
Samuel Cochran f2bb091bd1 denyhosts: 10.8 has no secure.log and logs sshd to system.log
Closes Homebrew/homebrew#18418.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2013-03-13 08:59:17 -07:00
Mike McQuaid 7d44b84aee Make generic caveats for launchd plist files. 2012-11-25 23:05:52 +00:00
Adam Vandenberg 2a1c4e34a2 caveat and other cleanups 2012-11-25 11:42:57 -08:00
Adam Vandenberg 230619e2c7 Let plists be installed automatically 2012-09-09 13:02:48 -07:00
Mike McQuaid 88779ade49 Batch convert MD5 formula to SHA1.
Closes Homebrew/homebrew#14653.
2012-09-03 11:36:42 -07:00
Adam Vandenberg c98de2e634 denyhosts: don't copy files in `def patches`
Replaced file-copy-plus-patch with entire versions
of files. Wonky, but we can't let real work happen in the `patches`
method during an install.
2012-03-17 21:29:16 -07:00
Adam Vandenberg 610aba9d3a denyhosts: use install_symlink 2012-02-12 20:08:56 -08:00
Jack Nagel 6ce735db99 Add and use plist helper methods
These will be used to unify the label namespaces in embedded plists,
i.e. 'homebrew.mxcl.<formula>'.

plist_path returns the full path to a plist file located at the top
level of the keg; plist_path.basename can be used if just the filename
is needed.

c.f. Homebrew/homebrew#9346.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-03 19:50:58 -06:00
Charlie Sharpsteen a66de23894 denyhosts: Fix script and plugin install paths
Ensure components don't wander into `/scripts` and `/plugins`.
2011-10-25 19:00:55 -07:00
Charlie Sharpsteen 08f5a812d3 DenyHosts: Fix CONFIG_FILE in constants.py
Substituted the value of a Python string variable without wrapping it in
quotes---this was causing the DenyHosts cron job to fail.
2011-09-25 22:35:07 -07:00
Charlie Sharpsteen 906fa9c9bf New Formula: DenyHosts
DenyHosts is a tool that monitors system logs for unauthorized SSH access
attempts and bans offending IP addresses by adding them to /etc/hosts.deny. A
launchctl plist is provided that runs the tool as a cron job. DenyHosts does
have a "daemon mode" but it is designed for rc.d style scripts and doesn't fit
the idiom that launchctl expects (direct control of the daemon process).

Also see issue Homebrew/homebrew#2955.
2011-09-24 14:01:50 -07:00