parent
15edee4543
commit
42ad186434
@ -0,0 +1,34 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/app-admin/durep/durep-0.9-r4.ebuild,v 1.1 2012/12/01 17:13:24 hasufell Exp $
|
||||
|
||||
EAPI=4
|
||||
inherit eutils
|
||||
|
||||
DESCRIPTION="A perl script designed for monitoring disk usage in a more visual way than du."
|
||||
HOMEPAGE="http://gentoo.org"
|
||||
SRC_URI="http://www.hibernaculum.net/download/${P}.tar.gz"
|
||||
|
||||
LICENSE="Artistic"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ppc ~x86"
|
||||
IUSE=""
|
||||
|
||||
DEPEND="dev-lang/perl"
|
||||
RDEPEND="${DEPEND}
|
||||
dev-perl/MLDBM
|
||||
virtual/perl-Getopt-Long
|
||||
virtual/perl-Term-ANSIColor"
|
||||
|
||||
src_prepare() {
|
||||
epatch "${FILESDIR}"/${P}-gigabyte.patch \
|
||||
"${FILESDIR}"/${PF}-color-output.patch \
|
||||
"${FILESDIR}"/${P}-dirhandle.patch
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dobin durep
|
||||
doman durep.1
|
||||
dodoc BUGS CHANGES README THANKS
|
||||
dohtml -A cgi *.cgi *.css *.png
|
||||
}
|
@ -0,0 +1,98 @@
|
||||
--- durep
|
||||
+++ durep
|
||||
@@ -14,6 +14,8 @@
|
||||
#############################################################################
|
||||
|
||||
use Getopt::Long;
|
||||
+use feature 'switch';
|
||||
+use Term::ANSIColor qw(:constants);
|
||||
use File::Basename;
|
||||
use MLDBM qw(DB_File Storable);
|
||||
use Fcntl;
|
||||
@@ -27,6 +29,7 @@
|
||||
our ($root_node, $filesystem_id, @stats);
|
||||
our ($opt_help, $opt_version, $opt_textdepth, $opt_hidesize, $opt_showdate, $opt_nosort, $opt_quiet);
|
||||
our ($opt_savefile, $opt_loadfile, $opt_desc, $opt_collate);
|
||||
+our ($opt_nocolor);
|
||||
our ($opt_files, $opt_onefilesystem, $opt_collapsepath, $opt_excludepath, $opt_coalescefiles);
|
||||
our ($root_dir, $file_count, $dir_count, $next_id);
|
||||
our ($TYPE_FILE, $TYPE_DIR, $TYPE_EMPTY, $TYPE_COALESCED, $TYPE_COLLAPSED);
|
||||
@@ -56,6 +59,8 @@
|
||||
"d|desc=s" => \$opt_desc,
|
||||
"c|collate=s" => \$opt_collate,
|
||||
|
||||
+ "nc|nocolor" => \$opt_nocolor,
|
||||
+
|
||||
"f|files" => \$opt_files,
|
||||
"x|one-file-system" => \$opt_onefilesystem,
|
||||
"cp|collapse-path=s" => \$opt_collapsepath,
|
||||
@@ -332,13 +337,58 @@
|
||||
printf(" [%s%s] ", "#" x $numofchars, " " x (30-$numofchars));
|
||||
printf("%6.2f%% ", $percent);
|
||||
printf("%s ", shortDate($entry->{MTIME})) if $opt_showdate;
|
||||
- printf("%s%s\n", $entry->{NAME}, $entry->{TYPE} & $TYPE_DIR ? "/" : "");
|
||||
+
|
||||
+ printColor( $entry ) unless ( $opt_nocolor );
|
||||
+ printNoColor( $entry ) if ( $opt_nocolor );
|
||||
if($entry->{TYPE} & $TYPE_DIR) {
|
||||
printDir($entry, $indent+1) if(!defined $opt_textdepth || ($opt_textdepth > $indent+1));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+sub printColor {
|
||||
+ my $entry = shift;
|
||||
+
|
||||
+ my @tmp = split /\./, $entry->{NAME};
|
||||
+
|
||||
+ if ( $entry->{TYPE} & $TYPE_DIR ) {
|
||||
+ print BLUE, BOLD, $entry->{NAME}."/\n", RESET
|
||||
+ }
|
||||
+ else {
|
||||
+ given ($tmp[$#tmp]) {
|
||||
+ #executable (bright green)
|
||||
+ when([ qw(cmd exe com btm bat sh csh) ]) {
|
||||
+ print BOLD, GREEN, $entry->{NAME}."\n", RESET
|
||||
+ }
|
||||
+ #archives / compressed (bright red)
|
||||
+ when([ qw(tar tgz arj taz lzh zip z Z gz bz2 tbz2 tz deb rpm rar ace zoo cpio 7z rz) ]) {
|
||||
+ print BOLD, RED, $entry->{NAME}."\n", RESET
|
||||
+ }
|
||||
+ #image formats
|
||||
+ when([ qw(jpg jpeg gif bmp ppm tga xbm xpm tif tiff png mng xcf pcx mpg mpeg m2v avi mkv
|
||||
+ ogm mp4 mp4v mov qt wmv asf rm rmvb flc fli gl dl) ]) {
|
||||
+ print BOLD, MAGENTA, $entry->{NAME}."\n", RESET
|
||||
+ }
|
||||
+ #misc.
|
||||
+ when([ qw(pdf ps txt patch diff log tex doc) ]) {
|
||||
+ print GREEN, $entry->{NAME}."\n", RESET
|
||||
+ }
|
||||
+ when([ qw(mp3 wav mid midi au ogg flac aac) ]) {
|
||||
+ print CYAN, $entry->{NAME}."\n", RESET
|
||||
+ }
|
||||
+ default {
|
||||
+ print $entry->{NAME}."\n", RESET
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+sub printNoColor {
|
||||
+ my $entry = shift;
|
||||
+
|
||||
+ printf("%s%s\n", $entry->{NAME}, $entry->{TYPE} & $TYPE_DIR ? "/" : "");
|
||||
+}
|
||||
+
|
||||
sub processSizeOption {
|
||||
my ($size, $temp);
|
||||
|
||||
@@ -438,6 +488,9 @@
|
||||
-d, --desc=<description> give description of save file
|
||||
-c, --collate=<dir> collate save files in dir for web report
|
||||
|
||||
+Color Option:
|
||||
+ -nc, --nocolor no color output
|
||||
+ By default durep color outpu
|
||||
Inclusion Options:
|
||||
-f, --files do not descend into subdirs, only report files
|
||||
-x, --one-file-system do not traverse file systems
|
@ -1,6 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||
<pkgmetadata>
|
||||
<maintainer><email>maintainer-needed@gentoo.org</email></maintainer>
|
||||
<longdescription>A perl script designed for monitoring disk usage. Similar to du</longdescription>
|
||||
<maintainer>
|
||||
<email>hasufell@gentoo.org</email>
|
||||
</maintainer>
|
||||
<longdescription>A perl script designed for monitoring disk usage. Similar to du</longdescription>
|
||||
</pkgmetadata>
|
||||
|
@ -1,2 +1 @@
|
||||
DIST nwipe-0.10.tar.gz 146741 SHA256 1f4c8b9eea74a31a2394d8b5980b2340e37d5f80814a5c75196081b7ad5621b0 SHA512 4ba0642c74282b159b374a4e8bbfc857d7079063996ae5c409c2242d4695a174ca54bd5b8973e91c375cb3b70478df5af22f552d5bb5456394e0a41c8823f5bd WHIRLPOOL e23690084d684c5a43075feb72d43f08ed23f964959c2706590da93d6d2c1ad404f8ba797fdae0b47c647b6cade84b8da978214cc65e6d82b72890777c8dbb2f
|
||||
DIST nwipe-0.11.tar.gz 146817 SHA256 8034e5ef434b7f32bc1d9a1bf00283f8a85eb1daa99b98b0d26fbbb3bba4a102 SHA512 c023ff02602d07aeb2a42aa7d6fc781d8ec830975cf3533c811dcd5dfbc1433aae01e25cdd329495b0d23c042e9de31a40659b76e799e251dc37a5c61e776b5a WHIRLPOOL d759a7dcc47cee12533aa2a6a31dc0a3000a72229241db8864f310801a82fdb3021aa26652161813505c3474fcaab5014d3e9b1e6c8762c0da6fe4597ab69124
|
||||
DIST nwipe-0.12.tar.gz 147380 SHA256 da70976acad36c8f500ecd27b1b0ac4beb81e909f8a761753cd23da37534596a SHA512 c05def96418824fdf372c24323d40c9b4e9fe7ce946af37d8d5bf4dff618c3af2d70dfec6819b89f1dedea835bab66cec2cf4206247c6c7c095aaa18c1bfbb2c WHIRLPOOL 243f840b98994e02dfa9f3737a297b68c754fa0c93f94b7c3799271605501f850f2392edea9e4e33828d15ea05d1d89012c221f073210b9b2e8ef607730201bd
|
||||
|
@ -1,24 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/app-crypt/nwipe/nwipe-0.11.ebuild,v 1.1 2012/10/03 17:43:35 ssuominen Exp $
|
||||
|
||||
EAPI=4
|
||||
inherit autotools
|
||||
|
||||
DESCRIPTION="Securely erase disks using a variety of recognized methods"
|
||||
HOMEPAGE="http://sourceforge.net/projects/nwipe/"
|
||||
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
RDEPEND=">=sys-block/parted-2.3
|
||||
>=sys-libs/ncurses-5.7-r7"
|
||||
DEPEND="${RDEPEND}"
|
||||
|
||||
DOCS="README"
|
||||
|
||||
# prevent maintainer mode
|
||||
src_prepare() { eautoreconf; }
|
@ -1,2 +1,3 @@
|
||||
DIST colordiff-1.0.10.tar.gz 17201 SHA256 425ef6c8b1599fbabab639a6629ddddd1272e9485f3d93e2549a2d28e0bf97f9 SHA512 b9dfba651adde06c62b83a127a5c6ced2a8cfd0c3619d9abe58a25c18c55c17dec818d477c065f3971a784836ec63895cf150c48491fa7dafebbe92596a515ca WHIRLPOOL 130f429dae35819e2f56d362e5821288a7639c5c60a37107bcf6b7d997bd7384eb9036ae50fc5b2a8393e9facc94376590b0340ab5240189837ad4c092c0580a
|
||||
DIST colordiff-1.0.12.tar.gz 17801 SHA256 cab7f87ae9572fae6de7bd74f260729a95470ec5effa50d5e4bd0d62a7957880 SHA512 d3e8fd354007752b32500ae9b80c8a4ca120b438d7fbaa747f61e109221a5c2f947773ef1d36afab11f95d10be05a1ab06edb12496c42f7acf6733b614bcff50 WHIRLPOOL 6f268f903a783971bdd4216f935c595f3c5584bb9bfd6c7615c129fc2aee11dde2ef7268bd92b2ebc51368570376fdb39099d2e8f893f3a2f738376ba30e7b29
|
||||
DIST colordiff-1.0.13.tar.gz 19960 SHA256 ce2805a130c81545711df94bc00a93545da3f323d835cc38b452d3396ef86c2a SHA512 8a47ea9e0c703d6b577a01e9a63df58233f752d4e72bb7f8213fcc076efcc52869df5e694126abbdc8a63816010786a577fa37ed3e175162dece3f17bd79fdda WHIRLPOOL 355d7ee12f37c19cf243bedff3d883ccd188da0e68c1531be932cec2d19055e67028cc5ca069f0bfe71d2c26538721989f13d1557d359338b534343b3c3faa4c
|
||||
|
@ -0,0 +1,37 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/app-misc/colordiff/colordiff-1.0.13.ebuild,v 1.1 2012/12/01 13:34:35 radhermit Exp $
|
||||
|
||||
EAPI=5
|
||||
|
||||
inherit prefix
|
||||
|
||||
DESCRIPTION="Colorizes output of diff"
|
||||
HOMEPAGE="http://www.colordiff.org/"
|
||||
SRC_URI="http://www.colordiff.org/${P}.tar.gz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~ppc-aix ~x86-fbsd ~hppa-hpux ~ia64-hpux ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x86-solaris"
|
||||
IUSE=""
|
||||
|
||||
RDEPEND="sys-apps/diffutils"
|
||||
|
||||
src_prepare() {
|
||||
# set proper etcdir for Gentoo Prefix
|
||||
sed -i -e "s:'/etc:'@GENTOO_PORTAGE_EPREFIX@/etc:" "${S}/colordiff.pl" \
|
||||
|| die "sed etcdir failed"
|
||||
eprefixify "${S}"/colordiff.pl
|
||||
}
|
||||
|
||||
# This package has a makefile, but we don't want to run it
|
||||
src_compile() { :; }
|
||||
|
||||
src_install() {
|
||||
newbin ${PN}{.pl,}
|
||||
newbin cdiff.sh cdiff
|
||||
insinto /etc
|
||||
doins colordiffrc colordiffrc-lightbg
|
||||
dodoc BUGS CHANGES README
|
||||
doman {cdiff,colordiff}.1
|
||||
}
|
@ -1,2 +1 @@
|
||||
DIST lirc-0.8.7.tar.bz2 832187 SHA256 e431454f266c4ddc209c3cc84fc506cac6092eb5124b4f3dcc215c8584ea7a39 SHA512 1ddc054a70949082dd7f8fed98d898da65e586c3fbf1de6751d8371fe693745842396315d3027d9c93e8237bb31d9126be84126c7c232fac19e12b196ef384ce WHIRLPOOL 973a2e5be2328d6866a064739e258bf28b32a503f89d1b1dbfcadd6b9e666513820406bca62d620b5091dcd8d53829f026e73422ed62fdfebafb6594e80e8624
|
||||
DIST lirc-0.9.0.tar.bz2 857286 SHA256 6323afae6ad498d4369675f77ec3dbb680fe661bea586aa296e67f2e2daba4ff SHA512 e91534c63e6065bd7da3b15e1676edf1672b8beb21864a6825df86247d7d165bf2dee6f8191732933e24e42a406e46afc55559948e4061eed2de7b08fac13431 WHIRLPOOL 0a1c00b07898aa7a5d78865fb73c6d26c6331dd0a4945773a801d29e40298b365eb58cae113a95fcf73be678a24ac082ad0868e8051303d732882fb82a859a7b
|
||||
|
@ -1,361 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/app-misc/lirc/lirc-0.8.7.ebuild,v 1.5 2012/01/09 07:19:17 ssuominen Exp $
|
||||
|
||||
EAPI=1
|
||||
|
||||
inherit eutils linux-mod flag-o-matic autotools
|
||||
|
||||
DESCRIPTION="decode and send infra-red signals of many commonly used remote controls"
|
||||
HOMEPAGE="http://www.lirc.org/"
|
||||
|
||||
MY_P=${PN}-${PV/_/}
|
||||
|
||||
if [[ "${PV/_pre/}" = "${PV}" ]]; then
|
||||
SRC_URI="mirror://sourceforge/lirc/${MY_P}.tar.bz2"
|
||||
else
|
||||
SRC_URI="http://www.lirc.org/software/snapshots/${MY_P}.tar.bz2"
|
||||
fi
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64 ppc x86"
|
||||
IUSE="debug doc X hardware-carrier transmitter"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
RDEPEND="
|
||||
X? (
|
||||
x11-libs/libX11
|
||||
x11-libs/libSM
|
||||
x11-libs/libICE
|
||||
)
|
||||
lirc_devices_alsa_usb? ( media-libs/alsa-lib )
|
||||
lirc_devices_audio? ( >media-libs/portaudio-18 )
|
||||
lirc_devices_irman? ( media-libs/libirman )"
|
||||
|
||||
# This are drivers with names matching the
|
||||
# parameter --with-driver=NAME
|
||||
IUSE_LIRC_DEVICES_DIRECT="
|
||||
all userspace accent act200l act220l
|
||||
adaptec alsa_usb animax asusdh atilibusb
|
||||
atiusb audio audio_alsa avermedia avermedia_vdomate
|
||||
avermedia98 awlibusb bestbuy bestbuy2 breakoutbox
|
||||
bte bw6130 caraca chronos commandir
|
||||
cph06x creative creative_infracd
|
||||
devinput digimatrix dsp dvico ea65 ene0100
|
||||
exaudio flyvideo ftdi gvbctv5pci hauppauge
|
||||
hauppauge_dvb hercules_smarttv_stereo i2cuser
|
||||
igorplugusb iguanaIR imon imon_24g imon_knob
|
||||
imon_lcd imon_pad imon_rsc irdeo irdeo_remote
|
||||
irlink irman irreal it87 ite8709
|
||||
knc_one kworld leadtek_0007 leadtek_0010
|
||||
leadtek_pvr2000 livedrive_midi
|
||||
livedrive_seq logitech macmini mceusb
|
||||
mediafocusI mouseremote
|
||||
mouseremote_ps2 mp3anywhere mplay nslu2
|
||||
packard_bell parallel pcmak pcmak_usb
|
||||
pctv pixelview_bt878 pixelview_pak
|
||||
pixelview_pro provideo realmagic
|
||||
remotemaster sa1100 samsung sasem sb0540 serial
|
||||
silitek sir slinke streamzap tekram
|
||||
tekram_bt829 tira ttusbir tuxbox tvbox udp uirt2
|
||||
uirt2_raw usb_uirt_raw usbx wpc8769l"
|
||||
|
||||
# drivers that need special handling and
|
||||
# must have another name specified for
|
||||
# parameter --with-driver=NAME
|
||||
IUSE_LIRC_DEVICES_SPECIAL="
|
||||
serial_igor_cesko
|
||||
remote_wonder_plus xboxusb usbirboy inputlirc"
|
||||
|
||||
IUSE_LIRC_DEVICES="${IUSE_LIRC_DEVICES_DIRECT} ${IUSE_LIRC_DEVICES_SPECIAL}"
|
||||
|
||||
#device-driver which use libusb
|
||||
LIBUSB_USED_BY_DEV="
|
||||
all atilibusb awlibusb sasem igorplugusb imon imon_lcd imon_pad
|
||||
imon_rsc streamzap mceusb xboxusb irlink commandir"
|
||||
|
||||
for dev in ${LIBUSB_USED_BY_DEV}; do
|
||||
DEPEND="${DEPEND} lirc_devices_${dev}? ( virtual/libusb:0 )"
|
||||
done
|
||||
|
||||
# adding only compile-time depends
|
||||
DEPEND="${RDEPEND} ${DEPEND}
|
||||
virtual/linux-sources
|
||||
lirc_devices_ftdi? ( dev-embedded/libftdi )
|
||||
lirc_devices_all? ( dev-embedded/libftdi )"
|
||||
|
||||
# adding only run-time depends
|
||||
RDEPEND="${RDEPEND}
|
||||
lirc_devices_usbirboy? ( app-misc/usbirboy )
|
||||
lirc_devices_inputlirc? ( app-misc/inputlircd )
|
||||
lirc_devices_iguanaIR? ( app-misc/iguanaIR )"
|
||||
|
||||
# add all devices to IUSE
|
||||
for dev in ${IUSE_LIRC_DEVICES}; do
|
||||
IUSE="${IUSE} lirc_devices_${dev}"
|
||||
done
|
||||
|
||||
add_device() {
|
||||
: ${lirc_device_count:=0}
|
||||
((lirc_device_count++))
|
||||
|
||||
if [[ ${lirc_device_count} -eq 2 ]]; then
|
||||
ewarn
|
||||
ewarn "When selecting multiple devices for lirc to be supported,"
|
||||
ewarn "it can not be guaranteed that the drivers play nice together."
|
||||
ewarn
|
||||
ewarn "If this is not intended, then abort emerge now with Ctrl-C,"
|
||||
ewarn "Set LIRC_DEVICES and restart emerge."
|
||||
ewarn
|
||||
epause
|
||||
fi
|
||||
|
||||
local dev="${1}"
|
||||
local desc="device ${dev}"
|
||||
if [[ -n "${2}" ]]; then
|
||||
desc="${2}"
|
||||
fi
|
||||
|
||||
elog "Compiling support for ${desc}"
|
||||
MY_OPTS="${MY_OPTS} --with-driver=${dev}"
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
|
||||
if use lirc_devices_mceusb2
|
||||
then
|
||||
ewarn "The mceusb2 driver has been merged into the mceusb."
|
||||
ewarn "Please only use the latter now."
|
||||
fi
|
||||
|
||||
ewarn "If your LIRC device requires modules, you'll need MODULE_UNLOAD"
|
||||
ewarn "support in your kernel."
|
||||
|
||||
linux-mod_pkg_setup
|
||||
|
||||
# set default configure options
|
||||
MY_OPTS=""
|
||||
LIRC_DRIVER_DEVICE="/dev/lirc0"
|
||||
|
||||
if use lirc_devices_all; then
|
||||
# compile in drivers for a lot of devices
|
||||
add_device all "a lot of devices"
|
||||
else
|
||||
# compile in only requested drivers
|
||||
local dev
|
||||
for dev in ${IUSE_LIRC_DEVICES_DIRECT}; do
|
||||
if use lirc_devices_${dev}; then
|
||||
add_device ${dev}
|
||||
fi
|
||||
done
|
||||
|
||||
if use lirc_devices_remote_wonder_plus; then
|
||||
add_device atiusb "device Remote Wonder Plus (atiusb-based)"
|
||||
fi
|
||||
|
||||
if use lirc_devices_serial_igor_cesko; then
|
||||
add_device serial "serial with Igor Cesko design"
|
||||
MY_OPTS="${MY_OPTS} --with-igor"
|
||||
fi
|
||||
|
||||
if use lirc_devices_imon_pad; then
|
||||
ewarn "The imon_pad driver has incorporated the previous pad2keys patch"
|
||||
ewarn "and removed the pad2keys_active option for the lirc_imon module"
|
||||
ewarn "because it is always active."
|
||||
ewarn "If you have an older imon VFD device, you may need to add the module"
|
||||
ewarn "option display_type=1 to override autodetection and force VFD mode."
|
||||
fi
|
||||
|
||||
if use lirc_devices_xboxusb; then
|
||||
add_device atiusb "device xboxusb"
|
||||
fi
|
||||
|
||||
if use lirc_devices_usbirboy; then
|
||||
add_device userspace "device usbirboy"
|
||||
LIRC_DRIVER_DEVICE="/dev/usbirboy"
|
||||
fi
|
||||
|
||||
if [[ "${MY_OPTS}" == "" ]]; then
|
||||
if [[ "${PROFILE_ARCH}" == "xbox" ]]; then
|
||||
# on xbox: use special driver
|
||||
add_device atiusb "device xboxusb"
|
||||
else
|
||||
# no driver requested
|
||||
elog
|
||||
elog "Compiling only the lirc-applications, but no drivers."
|
||||
elog "Enable drivers with LIRC_DEVICES if you need them."
|
||||
MY_OPTS="--with-driver=none"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
use hardware-carrier && MY_OPTS="${MY_OPTS} --without-soft-carrier"
|
||||
use transmitter && MY_OPTS="${MY_OPTS} --with-transmitter"
|
||||
|
||||
if [[ -n "${LIRC_OPTS}" ]] ; then
|
||||
ewarn
|
||||
ewarn "LIRC_OPTS is deprecated from lirc-0.8.0-r1 on."
|
||||
ewarn
|
||||
ewarn "Please use LIRC_DEVICES from now on."
|
||||
ewarn "e.g. LIRC_DEVICES=\"serial sir\""
|
||||
ewarn
|
||||
ewarn "Flags are now set per use-flags."
|
||||
ewarn "e.g. transmitter, hardware-carrier"
|
||||
|
||||
local opt
|
||||
local unsupported_opts=""
|
||||
|
||||
# test for allowed options for LIRC_OPTS
|
||||
for opt in ${LIRC_OPTS}; do
|
||||
case ${opt} in
|
||||
--with-port=*|--with-irq=*|--with-timer=*|--with-tty=*)
|
||||
MY_OPTS="${MY_OPTS} ${opt}"
|
||||
;;
|
||||
*)
|
||||
unsupported_opts="${unsupported_opts} ${opt}"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
if [[ -n ${unsupported_opts} ]]; then
|
||||
ewarn "These options are no longer allowed to be set"
|
||||
ewarn "with LIRC_OPTS: ${unsupported_opts}"
|
||||
die "LIRC_OPTS is no longer recommended."
|
||||
fi
|
||||
fi
|
||||
|
||||
# Setup parameter for linux-mod.eclass
|
||||
MODULE_NAMES="lirc(misc:${S})"
|
||||
BUILD_TARGETS="all"
|
||||
|
||||
ECONF_PARAMS=" --localstatedir=/var
|
||||
--with-syslog=LOG_DAEMON
|
||||
--enable-sandboxed
|
||||
--with-kerneldir=${KV_DIR}
|
||||
--with-moduledir=/lib/modules/${KV_FULL}/misc
|
||||
$(use_enable debug)
|
||||
$(use_with X x)
|
||||
${MY_OPTS}"
|
||||
|
||||
einfo
|
||||
einfo "lirc-configure-opts: ${MY_OPTS}"
|
||||
elog "Setting default lirc-device to ${LIRC_DRIVER_DEVICE}"
|
||||
|
||||
filter-flags -Wl,-O1
|
||||
|
||||
# force non-parallel make, Bug 196134
|
||||
MAKEOPTS="${MAKEOPTS} -j1"
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
unpack ${A}
|
||||
cd "${S}"
|
||||
|
||||
# Rip out dos CRLF
|
||||
edos2unix contrib/lirc.rules
|
||||
|
||||
# Apply patches needed for some special device-types
|
||||
use lirc_devices_audio || epatch "${FILESDIR}"/lirc-0.8.4-portaudio_check.patch
|
||||
use lirc_devices_remote_wonder_plus && epatch "${FILESDIR}"/lirc-0.8.3_pre1-remotewonderplus.patch
|
||||
|
||||
# remove parallel driver on SMP systems
|
||||
if linux_chkconfig_present SMP ; then
|
||||
sed -i -e "s:lirc_parallel\.o::" drivers/lirc_parallel/Makefile.am
|
||||
fi
|
||||
|
||||
# Bug #187418
|
||||
if kernel_is ge 2 6 22 ; then
|
||||
ewarn "Disabling lirc_gpio driver as it does no longer work Kernel 2.6.22+"
|
||||
sed -i -e "s:lirc_gpio\.o::" drivers/lirc_gpio/Makefile.am
|
||||
fi
|
||||
|
||||
# respect CFLAGS
|
||||
sed -i -e 's:CFLAGS="-O2:CFLAGS=""\n#CFLAGS="-O2:' configure.ac
|
||||
|
||||
# setting default device-node
|
||||
local f
|
||||
for f in configure.ac acconfig.h; do
|
||||
[[ -f "$f" ]] && sed -i -e '/#define LIRC_DRIVER_DEVICE/d' "$f"
|
||||
done
|
||||
echo "#define LIRC_DRIVER_DEVICE \"${LIRC_DRIVER_DEVICE}\"" >> acconfig.h
|
||||
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install || die "emake install failed"
|
||||
|
||||
newinitd "${FILESDIR}"/lircd-0.8.6 lircd
|
||||
newinitd "${FILESDIR}"/lircmd lircmd
|
||||
newconfd "${FILESDIR}"/lircd.conf.2 lircd
|
||||
|
||||
insinto /etc/modprobe.d/
|
||||
newins "${FILESDIR}"/modprobed.lirc lirc.conf
|
||||
|
||||
newinitd "${FILESDIR}"/irexec-initd-0.8.6-r2 irexec
|
||||
newconfd "${FILESDIR}"/irexec-confd irexec
|
||||
|
||||
if use doc ; then
|
||||
dohtml doc/html/*.html
|
||||
insinto /usr/share/doc/${PF}/images
|
||||
doins doc/images/*
|
||||
fi
|
||||
|
||||
insinto /usr/share/lirc/remotes
|
||||
doins -r remotes/*
|
||||
|
||||
keepdir /var/run/lirc /etc/lirc
|
||||
if [[ -e "${D}"/etc/lirc/lircd.conf ]]; then
|
||||
newdoc "${D}"/etc/lirc/lircd.conf lircd.conf.example
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
linux-mod_pkg_preinst
|
||||
|
||||
local dir="${ROOT}/etc/modprobe.d"
|
||||
if [[ -a "${dir}"/lirc && ! -a "${dir}"/lirc.conf ]]; then
|
||||
elog "Renaming ${dir}/lirc to lirc.conf"
|
||||
mv -f "${dir}/lirc" "${dir}/lirc.conf"
|
||||
fi
|
||||
|
||||
# copy the first file that can be found
|
||||
if [[ -f "${ROOT}"/etc/lirc/lircd.conf ]]; then
|
||||
cp "${ROOT}"/etc/lirc/lircd.conf "${T}"/lircd.conf
|
||||
elif [[ -f "${ROOT}"/etc/lircd.conf ]]; then
|
||||
cp "${ROOT}"/etc/lircd.conf "${T}"/lircd.conf
|
||||
MOVE_OLD_LIRCD_CONF=1
|
||||
elif [[ -f "${D}"/etc/lirc/lircd.conf ]]; then
|
||||
cp "${D}"/etc/lirc/lircd.conf "${T}"/lircd.conf
|
||||
fi
|
||||
|
||||
# stop portage from touching the config file
|
||||
if [[ -e "${D}"/etc/lirc/lircd.conf ]]; then
|
||||
rm -f "${D}"/etc/lirc/lircd.conf
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
linux-mod_pkg_postinst
|
||||
|
||||
# copy config file to new location
|
||||
# without portage knowing about it
|
||||
# so it will not delete it on unmerge or ever touch it again
|
||||
if [[ -e "${T}"/lircd.conf ]]; then
|
||||
cp "${T}"/lircd.conf "${ROOT}"/etc/lirc/lircd.conf
|
||||
if [[ "$MOVE_OLD_LIRCD_CONF" = "1" ]]; then
|
||||
elog "Moved /etc/lircd.conf to /etc/lirc/lircd.conf"
|
||||
rm -f "${ROOT}"/etc/lircd.conf
|
||||
fi
|
||||
fi
|
||||
|
||||
ewarn
|
||||
ewarn "The lirc_gpio driver will not work with Kernels 2.6.22+"
|
||||
ewarn "You need to switch over to /dev/input/event? if you need gpio"
|
||||
ewarn "This device can than then be used via lirc's dev/input driver."
|
||||
ewarn
|
||||
ewarn "The new default location for lircd.conf is inside of"
|
||||
ewarn "/etc/lirc/ directory"
|
||||
|
||||
}
|
@ -1,361 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/app-misc/lirc/lirc-0.9.0.ebuild,v 1.3 2012/01/09 07:19:17 ssuominen Exp $
|
||||
|
||||
EAPI=1
|
||||
|
||||
inherit eutils linux-mod flag-o-matic autotools
|
||||
|
||||
DESCRIPTION="decode and send infra-red signals of many commonly used remote controls"
|
||||
HOMEPAGE="http://www.lirc.org/"
|
||||
|
||||
MY_P=${PN}-${PV/_/}
|
||||
|
||||
if [[ "${PV/_pre/}" = "${PV}" ]]; then
|
||||
SRC_URI="mirror://sourceforge/lirc/${MY_P}.tar.bz2"
|
||||
else
|
||||
SRC_URI="http://www.lirc.org/software/snapshots/${MY_P}.tar.bz2"
|
||||
fi
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ppc ~x86"
|
||||
IUSE="debug doc X hardware-carrier transmitter"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
RDEPEND="
|
||||
X? (
|
||||
x11-libs/libX11
|
||||
x11-libs/libSM
|
||||
x11-libs/libICE
|
||||
)
|
||||
lirc_devices_alsa_usb? ( media-libs/alsa-lib )
|
||||
lirc_devices_audio? ( >media-libs/portaudio-18 )
|
||||
lirc_devices_irman? ( media-libs/libirman )"
|
||||
|
||||
# This are drivers with names matching the
|
||||
# parameter --with-driver=NAME
|
||||
IUSE_LIRC_DEVICES_DIRECT="
|
||||
all userspace accent act200l act220l
|
||||
adaptec alsa_usb animax asusdh atilibusb
|
||||
atiusb audio audio_alsa avermedia avermedia_vdomate
|
||||
avermedia98 awlibusb bestbuy bestbuy2 breakoutbox
|
||||
bte bw6130 caraca chronos commandir
|
||||
cph06x creative creative_infracd
|
||||
devinput digimatrix dsp dvico ea65 ene0100
|
||||
exaudio flyvideo ftdi gvbctv5pci hauppauge
|
||||
hauppauge_dvb hercules_smarttv_stereo i2cuser
|
||||
igorplugusb iguanaIR imon imon_24g imon_knob
|
||||
imon_lcd imon_pad imon_rsc irdeo irdeo_remote
|
||||
irlink irman irreal it87 ite8709
|
||||
knc_one kworld leadtek_0007 leadtek_0010
|
||||
leadtek_pvr2000 livedrive_midi
|
||||
livedrive_seq logitech macmini
|
||||
mediafocusI mouseremote
|
||||
mouseremote_ps2 mp3anywhere mplay nslu2
|
||||
packard_bell parallel pcmak pcmak_usb
|
||||
pctv pixelview_bt878 pixelview_pak
|
||||
pixelview_pro provideo realmagic
|
||||
remotemaster sa1100 samsung sasem sb0540 serial
|
||||
silitek sir slinke streamzap tekram
|
||||
tekram_bt829 tira ttusbir tuxbox tvbox udp uirt2
|
||||
uirt2_raw usb_uirt_raw usbx wpc8769l"
|
||||
|
||||
# drivers that need special handling and
|
||||
# must have another name specified for
|
||||
# parameter --with-driver=NAME
|
||||
IUSE_LIRC_DEVICES_SPECIAL="
|
||||
serial_igor_cesko
|
||||
remote_wonder_plus xboxusb usbirboy inputlirc"
|
||||
|
||||
IUSE_LIRC_DEVICES="${IUSE_LIRC_DEVICES_DIRECT} ${IUSE_LIRC_DEVICES_SPECIAL}"
|
||||
|
||||
#device-driver which use libusb
|
||||
LIBUSB_USED_BY_DEV="
|
||||
all atilibusb awlibusb sasem igorplugusb imon imon_lcd imon_pad
|
||||
imon_rsc streamzap xboxusb irlink commandir"
|
||||
|
||||
for dev in ${LIBUSB_USED_BY_DEV}; do
|
||||
DEPEND="${DEPEND} lirc_devices_${dev}? ( virtual/libusb:0 )"
|
||||
done
|
||||
|
||||
# adding only compile-time depends
|
||||
DEPEND="${RDEPEND} ${DEPEND}
|
||||
virtual/linux-sources
|
||||
lirc_devices_ftdi? ( dev-embedded/libftdi )
|
||||
lirc_devices_all? ( dev-embedded/libftdi )"
|
||||
|
||||
# adding only run-time depends
|
||||
RDEPEND="${RDEPEND}
|
||||
lirc_devices_usbirboy? ( app-misc/usbirboy )
|
||||
lirc_devices_inputlirc? ( app-misc/inputlircd )
|
||||
lirc_devices_iguanaIR? ( app-misc/iguanaIR )"
|
||||
|
||||
# add all devices to IUSE
|
||||
for dev in ${IUSE_LIRC_DEVICES}; do
|
||||
IUSE="${IUSE} lirc_devices_${dev}"
|
||||
done
|
||||
|
||||
add_device() {
|
||||
: ${lirc_device_count:=0}
|
||||
((lirc_device_count++))
|
||||
|
||||
if [[ ${lirc_device_count} -eq 2 ]]; then
|
||||
ewarn
|
||||
ewarn "When selecting multiple devices for lirc to be supported,"
|
||||
ewarn "it can not be guaranteed that the drivers play nice together."
|
||||
ewarn
|
||||
ewarn "If this is not intended, then abort emerge now with Ctrl-C,"
|
||||
ewarn "Set LIRC_DEVICES and restart emerge."
|
||||
ewarn
|
||||
epause
|
||||
fi
|
||||
|
||||
local dev="${1}"
|
||||
local desc="device ${dev}"
|
||||
if [[ -n "${2}" ]]; then
|
||||
desc="${2}"
|
||||
fi
|
||||
|
||||
elog "Compiling support for ${desc}"
|
||||
MY_OPTS="${MY_OPTS} --with-driver=${dev}"
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
|
||||
if use lirc_devices_mceusb2 || use lirc_devices_mceusb
|
||||
then
|
||||
ewarn "The mceusb2 and mceusb drivers have been merged into the mainline kernel"
|
||||
ewarn "Please only use the latter now and the userspace driver"
|
||||
fi
|
||||
|
||||
ewarn "If your LIRC device requires modules, you'll need MODULE_UNLOAD"
|
||||
ewarn "support in your kernel."
|
||||
|
||||
linux-mod_pkg_setup
|
||||
|
||||
# set default configure options
|
||||
MY_OPTS=""
|
||||
LIRC_DRIVER_DEVICE="/dev/lirc0"
|
||||
|
||||
if use lirc_devices_all; then
|
||||
# compile in drivers for a lot of devices
|
||||
add_device all "a lot of devices"
|
||||
else
|
||||
# compile in only requested drivers
|
||||
local dev
|
||||
for dev in ${IUSE_LIRC_DEVICES_DIRECT}; do
|
||||
if use lirc_devices_${dev}; then
|
||||
add_device ${dev}
|
||||
fi
|
||||
done
|
||||
|
||||
if use lirc_devices_remote_wonder_plus; then
|
||||
add_device atiusb "device Remote Wonder Plus (atiusb-based)"
|
||||
fi
|
||||
|
||||
if use lirc_devices_serial_igor_cesko; then
|
||||
add_device serial "serial with Igor Cesko design"
|
||||
MY_OPTS="${MY_OPTS} --with-igor"
|
||||
fi
|
||||
|
||||
if use lirc_devices_imon_pad; then
|
||||
ewarn "The imon_pad driver has incorporated the previous pad2keys patch"
|
||||
ewarn "and removed the pad2keys_active option for the lirc_imon module"
|
||||
ewarn "because it is always active."
|
||||
ewarn "If you have an older imon VFD device, you may need to add the module"
|
||||
ewarn "option display_type=1 to override autodetection and force VFD mode."
|
||||
fi
|
||||
|
||||
if use lirc_devices_xboxusb; then
|
||||
add_device atiusb "device xboxusb"
|
||||
fi
|
||||
|
||||
if use lirc_devices_usbirboy; then
|
||||
add_device userspace "device usbirboy"
|
||||
LIRC_DRIVER_DEVICE="/dev/usbirboy"
|
||||
fi
|
||||
|
||||
if [[ "${MY_OPTS}" == "" ]]; then
|
||||
if [[ "${PROFILE_ARCH}" == "xbox" ]]; then
|
||||
# on xbox: use special driver
|
||||
add_device atiusb "device xboxusb"
|
||||
else
|
||||
# no driver requested
|
||||
elog
|
||||
elog "Compiling only the lirc-applications, but no drivers."
|
||||
elog "Enable drivers with LIRC_DEVICES if you need them."
|
||||
MY_OPTS="--with-driver=none"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
use hardware-carrier && MY_OPTS="${MY_OPTS} --without-soft-carrier"
|
||||
use transmitter && MY_OPTS="${MY_OPTS} --with-transmitter"
|
||||
|
||||
if [[ -n "${LIRC_OPTS}" ]] ; then
|
||||
ewarn
|
||||
ewarn "LIRC_OPTS is deprecated from lirc-0.8.0-r1 on."
|
||||
ewarn
|
||||
ewarn "Please use LIRC_DEVICES from now on."
|
||||
ewarn "e.g. LIRC_DEVICES=\"serial sir\""
|
||||
ewarn
|
||||
ewarn "Flags are now set per use-flags."
|
||||
ewarn "e.g. transmitter, hardware-carrier"
|
||||
|
||||
local opt
|
||||
local unsupported_opts=""
|
||||
|
||||
# test for allowed options for LIRC_OPTS
|
||||
for opt in ${LIRC_OPTS}; do
|
||||
case ${opt} in
|
||||
--with-port=*|--with-irq=*|--with-timer=*|--with-tty=*)
|
||||
MY_OPTS="${MY_OPTS} ${opt}"
|
||||
;;
|
||||
*)
|
||||
unsupported_opts="${unsupported_opts} ${opt}"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
if [[ -n ${unsupported_opts} ]]; then
|
||||
ewarn "These options are no longer allowed to be set"
|
||||
ewarn "with LIRC_OPTS: ${unsupported_opts}"
|
||||
die "LIRC_OPTS is no longer recommended."
|
||||
fi
|
||||
fi
|
||||
|
||||
# Setup parameter for linux-mod.eclass
|
||||
MODULE_NAMES="lirc(misc:${S})"
|
||||
BUILD_TARGETS="all"
|
||||
|
||||
ECONF_PARAMS=" --localstatedir=/var
|
||||
--with-syslog=LOG_DAEMON
|
||||
--enable-sandboxed
|
||||
--with-kerneldir=${KV_DIR}
|
||||
--with-moduledir=/lib/modules/${KV_FULL}/misc
|
||||
$(use_enable debug)
|
||||
$(use_with X x)
|
||||
${MY_OPTS}"
|
||||
|
||||
einfo
|
||||
einfo "lirc-configure-opts: ${MY_OPTS}"
|
||||
elog "Setting default lirc-device to ${LIRC_DRIVER_DEVICE}"
|
||||
|
||||
filter-flags -Wl,-O1
|
||||
|
||||
# force non-parallel make, Bug 196134
|
||||
MAKEOPTS="${MAKEOPTS} -j1"
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
unpack ${A}
|
||||
cd "${S}"
|
||||
|
||||
# Rip out dos CRLF
|
||||
edos2unix contrib/lirc.rules
|
||||
|
||||
# Apply patches needed for some special device-types
|
||||
use lirc_devices_audio || epatch "${FILESDIR}"/lirc-0.8.4-portaudio_check.patch
|
||||
use lirc_devices_remote_wonder_plus && epatch "${FILESDIR}"/lirc-0.8.3_pre1-remotewonderplus.patch
|
||||
|
||||
# remove parallel driver on SMP systems
|
||||
if linux_chkconfig_present SMP ; then
|
||||
sed -i -e "s:lirc_parallel\.o::" drivers/lirc_parallel/Makefile.am
|
||||
fi
|
||||
|
||||
# Bug #187418
|
||||
if kernel_is ge 2 6 22 ; then
|
||||
ewarn "Disabling lirc_gpio driver as it does no longer work Kernel 2.6.22+"
|
||||
sed -i -e "s:lirc_gpio\.o::" drivers/lirc_gpio/Makefile.am
|
||||
fi
|
||||
|
||||
# respect CFLAGS
|
||||
sed -i -e 's:CFLAGS="-O2:CFLAGS=""\n#CFLAGS="-O2:' configure.ac
|
||||
|
||||
# setting default device-node
|
||||
local f
|
||||
for f in configure.ac acconfig.h; do
|
||||
[[ -f "$f" ]] && sed -i -e '/#define LIRC_DRIVER_DEVICE/d' "$f"
|
||||
done
|
||||
echo "#define LIRC_DRIVER_DEVICE \"${LIRC_DRIVER_DEVICE}\"" >> acconfig.h
|
||||
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install || die "emake install failed"
|
||||
|
||||
newinitd "${FILESDIR}"/lircd-0.8.6 lircd
|
||||
newinitd "${FILESDIR}"/lircmd lircmd
|
||||
newconfd "${FILESDIR}"/lircd.conf.2 lircd
|
||||
|
||||
insinto /etc/modprobe.d/
|
||||
newins "${FILESDIR}"/modprobed.lirc lirc.conf
|
||||
|
||||
newinitd "${FILESDIR}"/irexec-initd-0.8.6-r2 irexec
|
||||
newconfd "${FILESDIR}"/irexec-confd irexec
|
||||
|
||||
if use doc ; then
|
||||
dohtml doc/html/*.html
|
||||
insinto /usr/share/doc/${PF}/images
|
||||
doins doc/images/*
|
||||
fi
|
||||
|
||||
insinto /usr/share/lirc/remotes
|
||||
doins -r remotes/*
|
||||
|
||||
keepdir /var/run/lirc /etc/lirc
|
||||
if [[ -e "${D}"/etc/lirc/lircd.conf ]]; then
|
||||
newdoc "${D}"/etc/lirc/lircd.conf lircd.conf.example
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
linux-mod_pkg_preinst
|
||||
|
||||
local dir="${ROOT}/etc/modprobe.d"
|
||||
if [[ -a "${dir}"/lirc && ! -a "${dir}"/lirc.conf ]]; then
|
||||
elog "Renaming ${dir}/lirc to lirc.conf"
|
||||
mv -f "${dir}/lirc" "${dir}/lirc.conf"
|
||||
fi
|
||||
|
||||
# copy the first file that can be found
|
||||
if [[ -f "${ROOT}"/etc/lirc/lircd.conf ]]; then
|
||||
cp "${ROOT}"/etc/lirc/lircd.conf "${T}"/lircd.conf
|
||||
elif [[ -f "${ROOT}"/etc/lircd.conf ]]; then
|
||||
cp "${ROOT}"/etc/lircd.conf "${T}"/lircd.conf
|
||||
MOVE_OLD_LIRCD_CONF=1
|
||||
elif [[ -f "${D}"/etc/lirc/lircd.conf ]]; then
|
||||
cp "${D}"/etc/lirc/lircd.conf "${T}"/lircd.conf
|
||||
fi
|
||||
|
||||
# stop portage from touching the config file
|
||||
if [[ -e "${D}"/etc/lirc/lircd.conf ]]; then
|
||||
rm -f "${D}"/etc/lirc/lircd.conf
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
linux-mod_pkg_postinst
|
||||
|
||||
# copy config file to new location
|
||||
# without portage knowing about it
|
||||
# so it will not delete it on unmerge or ever touch it again
|
||||
if [[ -e "${T}"/lircd.conf ]]; then
|
||||
cp "${T}"/lircd.conf "${ROOT}"/etc/lirc/lircd.conf
|
||||
if [[ "$MOVE_OLD_LIRCD_CONF" = "1" ]]; then
|
||||
elog "Moved /etc/lircd.conf to /etc/lirc/lircd.conf"
|
||||
rm -f "${ROOT}"/etc/lircd.conf
|
||||
fi
|
||||
fi
|
||||
|
||||
ewarn
|
||||
ewarn "The lirc_gpio driver will not work with Kernels 2.6.22+"
|
||||
ewarn "You need to switch over to /dev/input/event? if you need gpio"
|
||||
ewarn "This device can than then be used via lirc's dev/input driver."
|
||||
ewarn
|
||||
ewarn "The new default location for lircd.conf is inside of"
|
||||
ewarn "/etc/lirc/ directory"
|
||||
|
||||
}
|
@ -1 +1,2 @@
|
||||
DIST mksh-R40f.cpio.gz 331196 SHA256 d8657102f3e9f0c432388f1c820821ebe0eee442739604293488e6266c298762 SHA512 a396ef02aecd713d44597da286bac2bdfe12f12f9712ebc21825283f3900bfca5b79125ca7e191c9970bde761e7873fc68ad3c822238e70697d65eb373560c75 WHIRLPOOL 4627639d67155cdfe09d0bff1fc16abf4111654a8538378ed4465fd71013e9562869c967bdcecf7c300712363775ef6cd67ae51c1cb52424c6a1ae36f2db68f8
|
||||
DIST mksh-R41.tgz 341489 SHA256 32522287a9d4daad176dc97d420000a07c0947fdbc853004fc84f02dbdd87c91 SHA512 b28c52face5227964fee8dd60f088e4c0866c3572240a0d9529c31f49892f7589fb68db4ed58528b51e4dd7cfc1f94713755eb4cd0fc6bd257c39954f9a463f3 WHIRLPOOL b8a6d90d42311384a9384f8948e6307941994dbd8d77647c6f203ab77089624474e6809f71df4da2e6735a4e2119b6dceedd6d8f5a56eeddce10c575da7e2d29
|
||||
|
@ -0,0 +1,37 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/app-shells/mksh/mksh-41.ebuild,v 1.1 2012/12/01 03:12:33 patrick Exp $
|
||||
|
||||
EAPI=4
|
||||
|
||||
inherit eutils toolchain-funcs unpacker
|
||||
|
||||
DESCRIPTION="MirBSD KSH Shell"
|
||||
HOMEPAGE="http://mirbsd.de/mksh"
|
||||
ARC4_VERSION="1.14"
|
||||
SRC_URI="http://www.mirbsd.org/MirOS/dist/mir/mksh/${PN}-R${PV}.tgz"
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ppc ~x86 ~amd64-linux ~x86-linux"
|
||||
IUSE=""
|
||||
DEPEND="app-arch/cpio"
|
||||
RDEPEND=""
|
||||
S="${WORKDIR}/${PN}"
|
||||
|
||||
src_compile() {
|
||||
tc-export CC
|
||||
export CPPFLAGS="${CPPFLAGS} -DMKSH_DEFAULT_PROFILEDIR=\\\"${EPREFIX}/etc\\\""
|
||||
# we can't assume lto existing/enabled, so we add a fallback
|
||||
sh Build.sh -r -c lto || sh Rebuild.sh || die
|
||||
}
|
||||
|
||||
src_install() {
|
||||
exeinto /bin
|
||||
doexe mksh
|
||||
doman mksh.1
|
||||
dodoc dot.mkshrc
|
||||
}
|
||||
|
||||
src_test() {
|
||||
./test.sh || die
|
||||
}
|
@ -1,2 +1,3 @@
|
||||
DIST calibre-0.9.6.tar.xz 27346664 SHA256 d2cb83a8fc32b3258f3a491f33f4271bfd4020ac4fdbbf01131deb81bba9624f SHA512 6bbacc8ed9af318bdfc09807937ec5e3e2d99a9b1d408cbf4dd4976926b415736928a16ee8d712ae1b93e98ab612841123bb370440c78db9c350ebd6503f8e58 WHIRLPOOL 306662c0b7dae93ec0d5c63903e02fc6a9cdf6427290bd366464dca7c618f602380fec9767a23baafaf1257135f333553c345356bf06560785c0664f9d74cf36
|
||||
DIST calibre-0.9.7.tar.xz 27408848 SHA256 11c861aaed751e53f3a97164a4e879d6afc5aed7e395aca9a62ae1feff2d29a7 SHA512 51367dea7171861095dd01eeee985be3018b811ad25a294d523b59414b2e3eabd198e40d8528b417295cdad39260059bade71967fd305699c559cf341494b3fa WHIRLPOOL 3ed4741a5e52bdba9c51d2c2c9003de72aa8a299f034ba8a1c1455ce1f817b01c97ab6f960eee03f942b04d9ecb44ebb74616b209fee64249f104cd28e4d0205
|
||||
DIST calibre-0.9.8.tar.xz 27624924 SHA256 8535ef31d8ade68399f6eae110c5929cde2ad2f27c9930648fc93e8e80379e9f SHA512 11b5049f6e8ee47c11dbf7fe03bb59bc6af3b1db27c2205127288bffbd1f4162b8a317e003c17ce12197b9d31fbf9c4a9fcb64d101bd2475b7357b19a0e58b2c WHIRLPOOL f49de7235d6f64b7c71a1cbee0499ca47c292e3ec7d5988053ba8a5e6e09de99603238b473efe5b63ed7b631cffaeeaa300628eacc0f51cb60f84c62431063b7
|
||||
|
@ -0,0 +1,184 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/app-text/calibre/calibre-0.9.8.ebuild,v 1.1 2012/11/30 09:10:22 zmedico Exp $
|
||||
|
||||
EAPI=4
|
||||
PYTHON_DEPEND=2:2.7
|
||||
PYTHON_USE_WITH="ssl sqlite"
|
||||
|
||||
inherit python eutils fdo-mime bash-completion-r1 multilib
|
||||
|
||||
DESCRIPTION="Ebook management application."
|
||||
HOMEPAGE="http://calibre-ebook.com/"
|
||||
SRC_URI="http://sourceforge.net/projects/calibre/files/${PV}/${P}.tar.xz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
|
||||
SLOT="0"
|
||||
|
||||
IUSE="+udisks"
|
||||
|
||||
COMMON_DEPEND="
|
||||
>=app-text/podofo-0.8.2
|
||||
>=app-text/poppler-0.12.3-r3[qt4,xpdf-headers(+)]
|
||||
>=dev-libs/chmlib-0.40
|
||||
>=dev-libs/icu-4.4
|
||||
>=dev-python/beautifulsoup-3.0.5:python-2
|
||||
dev-python/netifaces
|
||||
dev-python/python-dateutil
|
||||
>=dev-python/dnspython-1.6.0
|
||||
>=dev-python/cssselect-0.7.1
|
||||
>=dev-python/cssutils-0.9.9
|
||||
>=dev-python/dbus-python-0.82.2
|
||||
>=dev-python/imaging-1.1.6
|
||||
>=dev-python/lxml-2.2.1
|
||||
>=dev-python/mechanize-0.1.11
|
||||
>=dev-python/python-dateutil-1.4.1
|
||||
>=dev-python/PyQt4-4.9.1[X,svg,webkit]
|
||||
media-fonts/liberation-fonts
|
||||
>=media-gfx/imagemagick-6.5.9[jpeg,png]
|
||||
>=media-libs/freetype-2
|
||||
>=media-libs/libwmf-0.2.8
|
||||
>=media-libs/libmtp-1.1.4
|
||||
virtual/libusb:1
|
||||
x11-libs/qt-dbus:4
|
||||
x11-libs/qt-svg:4
|
||||
>=x11-misc/xdg-utils-1.0.2-r2"
|
||||
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
udisks? ( || ( sys-fs/udisks:2 sys-fs/udisks:0 ) )"
|
||||
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
>=dev-python/setuptools-0.6_rc5"
|
||||
|
||||
S=${WORKDIR}/${PN}
|
||||
|
||||
pkg_setup() {
|
||||
python_set_active_version 2.7
|
||||
python_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Fix outdated version constant.
|
||||
#sed -e "s#\\(^numeric_version =\\).*#\\1 (${PV//./, })#" \
|
||||
# -i src/calibre/constants.py || \
|
||||
# die "sed failed to patch constants.py"
|
||||
|
||||
# Avoid sandbox violation in /usr/share/gnome/apps when linux.py
|
||||
# calls xdg-* (bug #258938).
|
||||
sed -e "s|'xdg-desktop-menu', 'install'|\\0, '--mode', 'user'|" \
|
||||
-e "s|check_call(\\['xdg-desktop-menu', 'forceupdate'\\])|#\\0|" \
|
||||
-e "s|\\(CurrentDir(tdir)\\), \\\\\$|\\1:|" \
|
||||
-e "s|PreserveMIMEDefaults():||" \
|
||||
-e "s|xdg-icon-resource install|\\0 --mode user|" \
|
||||
-e "s|cc(\\['xdg-desktop-menu', 'forceupdate'\\])|#\\0|" \
|
||||
-e "s|xdg-mime install|\\0 --mode user|" \
|
||||
-i src/calibre/linux.py || die "sed failed to patch linux.py"
|
||||
|
||||
# Disable unnecessary privilege dropping for bug #287067.
|
||||
sed -e "s:if os.geteuid() == 0:if False and os.geteuid() == 0:" \
|
||||
-i setup/install.py || die "sed failed to patch install.py"
|
||||
|
||||
sed -e "/^ self\\.check_call(qmc + \\[.*\\.pro'\\])$/a\
|
||||
\\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ self.check_call(['sed', \
|
||||
'-e', 's|^CFLAGS .*|\\\\\\\\0 ${CFLAGS}|', \
|
||||
'-e', 's|^CXXFLAGS .*|\\\\\\\\0 ${CXXFLAGS}|', \
|
||||
'-e', 's|^LFLAGS .*|\\\\\\\\0 ${LDFLAGS}|', \
|
||||
'-i', 'Makefile'])" \
|
||||
-i setup/extensions.py || die "sed failed to patch extensions.py"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
|
||||
# Bypass kbuildsycoca and update-mime-database in order to
|
||||
# avoid sandbox violations if xdg-mime tries to call them.
|
||||
cat - > "${T}/kbuildsycoca" <<-EOF
|
||||
#!${BASH}
|
||||
exit 0
|
||||
EOF
|
||||
|
||||
cp "${T}"/{kbuildsycoca,update-mime-database}
|
||||
chmod +x "${T}"/{kbuildsycoca,update-mime-database}
|
||||
|
||||
# Unset DISPLAY in order to prevent xdg-mime from triggering a sandbox
|
||||
# violation with kbuildsycoca as in bug #287067, comment #13.
|
||||
export -n DISPLAY
|
||||
|
||||
# Bug #352625 - Some LANGUAGE values can trigger the following ValueError:
|
||||
# File "/usr/lib/python2.6/locale.py", line 486, in getdefaultlocale
|
||||
# return _parse_localename(localename)
|
||||
# File "/usr/lib/python2.6/locale.py", line 418, in _parse_localename
|
||||
# raise ValueError, 'unknown locale: %s' % localename
|
||||
#ValueError: unknown locale: 46
|
||||
export -n LANGUAGE
|
||||
|
||||
# Bug #295672 - Avoid sandbox violation in ~/.config by forcing
|
||||
# variables to point to our fake temporary $HOME.
|
||||
export HOME="${T}/fake_homedir"
|
||||
export XDG_CONFIG_HOME="${HOME}/.config"
|
||||
export XDG_DATA_HOME="${HOME}/.local/share"
|
||||
export CALIBRE_CONFIG_DIRECTORY="${XDG_CONFIG_HOME}/calibre"
|
||||
mkdir -p "${XDG_CONFIG_HOME}" "${CALIBRE_CONFIG_DIRECTORY}"
|
||||
|
||||
# Bug #334243 - respect LDFLAGS when building calibre-mount-helper
|
||||
export OVERRIDE_CFLAGS="$CFLAGS" OVERRIDE_LDFLAGS="$LDFLAGS"
|
||||
local libdir=$(get_libdir)
|
||||
[[ -n $libdir ]] || die "get_libdir returned an empty string"
|
||||
|
||||
dodir "$(python_get_sitedir)" # for init_calibre.py
|
||||
PATH=${T}:${PATH} PYTHONPATH=${S}/src${PYTHONPATH:+:}${PYTHONPATH} \
|
||||
python setup.py install \
|
||||
--root="${D}" \
|
||||
--prefix="${EPREFIX}/usr" \
|
||||
--libdir="${EPREFIX}/usr/${libdir}" \
|
||||
--staging-root="${ED}usr" \
|
||||
--staging-libdir="${ED}usr/${libdir}" || die
|
||||
|
||||
grep -rlZ "${ED}" "${ED}" | xargs -0 sed -e "s:${D}:/:g" -i ||
|
||||
die "failed to fix harcoded \$D in paths"
|
||||
|
||||
# Remove dummy calibre-mount-helper which is unused since calibre-0.8.25
|
||||
# due to bug #389515 (instead, calibre now calls udisks via dbus).
|
||||
rm "${ED}usr/bin/calibre-mount-helper" || die
|
||||
|
||||
# The menu entries end up here due to '--mode user' being added to
|
||||
# xdg-* options in src_prepare.
|
||||
dodir /usr/share/mime/packages
|
||||
chmod -fR a+rX,u+w,g-w,o-w "${HOME}"/.local
|
||||
mv "${HOME}"/.local/share/mime/packages/* "${ED}"usr/share/mime/packages/ ||
|
||||
die "failed to register mime types"
|
||||
dodir /usr/share/icons
|
||||
mv "${HOME}"/.local/share/icons/* "${ED}"usr/share/icons/ ||
|
||||
die "failed to install icon files"
|
||||
|
||||
domenu "${HOME}"/.local/share/applications/*.desktop ||
|
||||
die "failed to install .desktop menu files"
|
||||
|
||||
dobashcomp "${ED}"usr/etc/bash_completion.d/calibre
|
||||
rm -r "${ED}"usr/etc/bash_completion.d
|
||||
find "${ED}"usr/etc -type d -empty -delete
|
||||
|
||||
cd "${ED}"/usr/share/calibre/fonts/liberation || die
|
||||
local x
|
||||
for x in * ; do
|
||||
[[ -f ${EROOT}usr/share/fonts/liberation-fonts/${x} ]] || continue
|
||||
ln -sf "../../../fonts/liberation-fonts/${x}" "${x}" || die
|
||||
done
|
||||
|
||||
python_convert_shebangs -r $(python_get_version) "${ED}"
|
||||
|
||||
newinitd "${FILESDIR}"/calibre-server.init calibre-server
|
||||
newconfd "${FILESDIR}"/calibre-server.conf calibre-server
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
fdo-mime_desktop_database_update
|
||||
fdo-mime_mime_database_update
|
||||
python_mod_optimize /usr/$(get_libdir)/${PN}
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
python_mod_cleanup /usr/$(get_libdir)/${PN}
|
||||
}
|
@ -1,2 +1 @@
|
||||
DIST liblangtag-0.3.tar.bz2 569046 SHA256 47d3bf2824df0df409219d2061c99adac11019151315e5372f6844bba1f4de4d SHA512 a0c44964a8c6c2b360657679159d2cd47b51fc5b400b338a0a358cb7569b40b8912bb7189cfb6cacb4851d8f325fe9a53a88a3fa7cf1bd0f494bb90574de533c WHIRLPOOL 54ec883fe810b392cb05c1382d49a0fc1f629b55a31a027a9395c8e7ecb9b7884eb6cc3136766830fbf79a4ea14c6a884b5ea8bef69cb300e654ce65156636ac
|
||||
DIST liblangtag-0.4.0.tar.bz2 613182 SHA256 cbb71d5d1af345c3bd9ceebbc78ddfbe70e3747c3cf95532a4fdef2abb034bae SHA512 d04f188d8cad68504d322bb9461f1be564ae831735afbde4b9f7a7b09819ba20b2e9a72f68e7660e69d8b80d33ea2beb4bfcbb6f521d58c06b2c2182fd7928c8 WHIRLPOOL 420c39e7c6ff7b12f071538338611430b9edb4322c3cf9fe2df2276bbd6a7aaa288958a01316cf885edd285e38fea59fd1ce2c8dbed9d78694dab37606e0abe5
|
||||
|
@ -1,38 +0,0 @@
|
||||
diff -urN liblangtag-0.3.old/configure.ac liblangtag-0.3/configure.ac
|
||||
--- liblangtag-0.3.old/configure.ac 2012-08-07 13:05:39.078159231 +0200
|
||||
+++ liblangtag-0.3/configure.ac 2012-08-07 13:10:43.595164908 +0200
|
||||
@@ -88,9 +88,18 @@
|
||||
PKG_CHECK_MODULES(LIBXML2, libxml-2.0 >= $LIBXML2_REQUIRED)
|
||||
PKG_CHECK_MODULES(GOBJECT, gobject-2.0 >= $GOBJECT_REQUIRED, has_gobject=yes, has_gobject=no)
|
||||
PKG_CHECK_MODULES(GMODULE, gmodule-2.0, has_gmodule=yes, has_gmodule=no)
|
||||
-PKG_CHECK_MODULES(CHECK, check >= $CHECK_REQUIRED,
|
||||
- [use_check="yes"],
|
||||
- [use_check="no"])
|
||||
+AC_ARG_ENABLE([test],
|
||||
+ [AC_HELP_STRING([--disable-test], [Disable tests])],
|
||||
+ [enable_test="$enableval"],
|
||||
+ [enable_test=yes]
|
||||
+)
|
||||
+if test x"$enable_test" != x"no"; then
|
||||
+ PKG_CHECK_MODULES(CHECK, check >= $CHECK_REQUIRED,
|
||||
+ [use_check="yes"],
|
||||
+ [use_check="no"])
|
||||
+else
|
||||
+ use_check=no
|
||||
+fi
|
||||
|
||||
if test x$has_gmodule != xno; then
|
||||
AC_DEFINE(ENABLE_GMODULE,, [Using gmodule])
|
||||
diff -urN liblangtag-0.3.old/Makefile.am liblangtag-0.3/Makefile.am
|
||||
--- liblangtag-0.3.old/Makefile.am 2012-08-07 13:05:39.067159226 +0200
|
||||
+++ liblangtag-0.3/Makefile.am 2012-08-07 13:15:50.431169857 +0200
|
||||
@@ -10,8 +10,7 @@
|
||||
SUBDIRS += tests
|
||||
|
||||
ACLOCAL_AMFLAGS = \
|
||||
- -I m4macros \
|
||||
- $(NULL)
|
||||
+ -I m4macros
|
||||
|
||||
CONFIGURE_DEPENDENCIES = \
|
||||
requires \
|
@ -1,60 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/app-text/liblangtag/liblangtag-0.3-r1.ebuild,v 1.2 2012/09/21 07:22:09 scarabeus Exp $
|
||||
|
||||
EAPI=4
|
||||
|
||||
inherit base autotools
|
||||
|
||||
DESCRIPTION="An interface library to access tags for identifying languages"
|
||||
HOMEPAGE="https://github.com/tagoh/liblangtag/"
|
||||
SRC_URI="https://github.com/downloads/tagoh/${PN}/${P}.tar.bz2"
|
||||
|
||||
LICENSE="LGPL-3"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ppc ~x86"
|
||||
IUSE="introspection static-libs test"
|
||||
|
||||
RDEPEND="
|
||||
dev-libs/glib
|
||||
dev-libs/libxml2
|
||||
introspection? ( >=dev-libs/gobject-introspection-0.10.8 )
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
sys-devel/gettext
|
||||
test? ( dev-libs/check )
|
||||
>=dev-util/gtk-doc-am-1.13
|
||||
dev-libs/gobject-introspection-common
|
||||
"
|
||||
# gtk-doc-am and gobject-introspection-common required by autoreconf
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/${P}-automagic-tests.patch"
|
||||
)
|
||||
|
||||
# Upstream expect liblangtag to be installed when one runs tests...
|
||||
RESTRICT="test"
|
||||
|
||||
src_prepare() {
|
||||
base_src_prepare
|
||||
|
||||
# fixed in git
|
||||
sed -i \
|
||||
-e 's:$(libdir):${libdir}:g' \
|
||||
*.pc.in || die
|
||||
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
econf \
|
||||
$(use_enable introspection) \
|
||||
$(use_enable static-libs static) \
|
||||
$(use_enable test)
|
||||
}
|
||||
|
||||
src_install() {
|
||||
default
|
||||
|
||||
find "${ED}" -name '*.la' -exec rm -f {} +
|
||||
}
|
@ -0,0 +1,106 @@
|
||||
http://bugzilla.xfce.org/show_bug.cgi?id=9568
|
||||
|
||||
--- src/entry_edit_dialog.c
|
||||
+++ src/entry_edit_dialog.c
|
||||
@@ -17,7 +17,7 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <config.h>
|
||||
-#include <libxfcegui4/libxfcegui4.h>
|
||||
+#include <libxfce4ui/libxfce4ui.h>
|
||||
|
||||
#include "entry_edit_dialog.h"
|
||||
#include "entry.h"
|
||||
@@ -589,11 +589,13 @@
|
||||
key = (char *) gtk_entry_get_text(GTK_ENTRY(key_entry));
|
||||
if ((type = gtk_combo_box_get_active_text(GTK_COMBO_BOX(combobox))) == NULL) {
|
||||
_DEBUG(("No type selected"));
|
||||
- xfce_warn(_("No type was selected"));
|
||||
+ /* xfce_warn(_("No type was selected")); */
|
||||
+ xfce_dialog_show_warning(NULL,NULL,_("No type was selected"));
|
||||
continue;
|
||||
} else if (strcmp(key, "") == 0) {
|
||||
_DEBUG(("No key selected"));
|
||||
- xfce_warn(_("No key was selected"));
|
||||
+ /* xfce_warn(_("No key was selected")); */
|
||||
+ xfce_dialog_show_warning(NULL,NULL,_("No key was selected"));
|
||||
continue;
|
||||
} else {
|
||||
if (selected == NULL) {
|
||||
--- src/menubar.c
|
||||
+++ src/menubar.c
|
||||
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
-#include <libxfcegui4/libxfcegui4.h>
|
||||
+#include <libxfce4ui/libxfce4ui.h>
|
||||
#include <libintl.h>
|
||||
#include <config.h>
|
||||
|
||||
--- src/open.c
|
||||
+++ src/open.c
|
||||
@@ -14,7 +14,7 @@
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
-#include <libxfcegui4/libxfcegui4.h>
|
||||
+#include <libxfce4ui/libxfce4ui.h>
|
||||
#include <config.h>
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
--- src/open_dialog.c
|
||||
+++ src/open_dialog.c
|
||||
@@ -14,7 +14,7 @@
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
-#include <libxfcegui4/libxfcegui4.h>
|
||||
+#include <libxfce4ui/libxfce4ui.h>
|
||||
#include <libintl.h>
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
--- src/save_dialog.c
|
||||
+++ src/save_dialog.c
|
||||
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
|
||||
#include <libintl.h>
|
||||
-#include <libxfcegui4/libxfcegui4.h>
|
||||
+#include <libxfce4ui/libxfce4ui.h>
|
||||
#include <config.h>
|
||||
|
||||
#include "xfbib.h"
|
||||
--- src/string_edit_dialog.c
|
||||
+++ src/string_edit_dialog.c
|
||||
@@ -15,7 +15,7 @@
|
||||
*/
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
-#include <libxfcegui4/libxfcegui4.h>
|
||||
+#include <libxfce4ui/libxfce4ui.h>
|
||||
|
||||
#include "debug.h"
|
||||
#include "strings.h"
|
||||
--- src/treeview.c
|
||||
+++ src/treeview.c
|
||||
@@ -14,7 +14,7 @@
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
-#include <libxfcegui4/libxfcegui4.h>
|
||||
+#include <libxfce4ui/libxfce4ui.h>
|
||||
#include <libintl.h>
|
||||
#include <config.h>
|
||||
#include <string.h>
|
||||
--- src/xfbib.c
|
||||
+++ src/xfbib.c
|
||||
@@ -20,7 +20,7 @@
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
#include <stdlib.h>
|
||||
-#include <libxfcegui4/libxfcegui4.h>
|
||||
+#include <libxfce4ui/libxfce4ui.h>
|
||||
#include <libintl.h>
|
||||
|
||||
#include "window.h"
|
@ -0,0 +1,19 @@
|
||||
--- xfbib.desktop
|
||||
+++ xfbib.desktop
|
||||
@@ -1,13 +1,11 @@
|
||||
-
|
||||
[Desktop Entry]
|
||||
-Encoding=UTF-8
|
||||
Name=Xfbib
|
||||
Exec=xfbib
|
||||
Icon=xfbib
|
||||
Type=Application
|
||||
Comment=A BibTeX editor for Xfce
|
||||
-Terminal=0
|
||||
-MimeType=text/x-bibtex
|
||||
-Categories=Application;Office;GTK;
|
||||
+Terminal=false
|
||||
+MimeType=text/x-bibtex;
|
||||
+Categories=Office;GTK;
|
||||
GenericName=
|
||||
StartupNotify=false
|
@ -0,0 +1,41 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/app-text/xfbib/xfbib-0.0.2-r1.ebuild,v 1.1 2012/11/30 23:43:45 ssuominen Exp $
|
||||
|
||||
EAPI=5
|
||||
inherit xfconf
|
||||
|
||||
DESCRIPTION="a lightweight BibTeX editor"
|
||||
HOMEPAGE="http://goodies.xfce.org/projects/applications/xfbib"
|
||||
SRC_URI="http://goodies.xfce.org/releases/${PN}/${P}.tar.bz2"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
RDEPEND=">=dev-libs/glib-2.12
|
||||
>=x11-libs/gtk+-2.10:2
|
||||
>=xfce-base/libxfce4ui-4.8
|
||||
>=xfce-base/libxfce4util-4.8"
|
||||
DEPEND="${RDEPEND}
|
||||
dev-util/intltool
|
||||
sys-devel/gettext
|
||||
virtual/pkgconfig"
|
||||
|
||||
pkg_setup() {
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${P}-validate.patch
|
||||
"${FILESDIR}"/${P}-libxfce4ui.patch
|
||||
)
|
||||
|
||||
DOCS=( AUTHORS ChangeLog NEWS README TODO )
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# This is to prevent eautoreconfigure:
|
||||
sed -i -e 's:libxfcegui4-1.0:libxfce4ui-1:' configure || die
|
||||
sed -i -e 's:$(LIBXFCE4UTIL_CFLAGS):& $(LIBXFCEGUI4_CFLAGS):' src/Makefile.in || die
|
||||
|
||||
xfconf_src_prepare
|
||||
}
|
@ -1 +1,2 @@
|
||||
DIST cbind-6.0.1.tar.bz2 69865 SHA256 dd602e065e1c925995c1b5bdaaef338f94053bfd4391f18527ce96e8ca521689 SHA512 160535ac298ad5e2873cc3de5455a25750dba6df9c7a56a28474a02985b8f7ffdab0039392586e742b0fea1e4e8dcddef2e674205b0b408459b768a0dc1a5b05 WHIRLPOOL 3b8f59643990c8d30f70cfabd83937d28ec0a6f9bdf0274e1cb007cac8433d6534107a658c296f7bb14c07d7a04ebd62f56c0bbe1e421b2815f68a733d382476
|
||||
DIST cbind-6.0.tar.bz2 69853 SHA256 dc4a0c67ac0066f065f1424cd6682d70036bb428fd1a85aeb85d760be9a519cb SHA512 f8ee658363a745e44261d29072f494b92e56f679cfaabc02520b8a4c7eff2182ca165fcdf91be07eca05bb9ceadb60c3c473ccee9739f119b0086292ec2780b4 WHIRLPOOL 25b496635bdae944bbb15d0b3e43bdddb0333c83d5164fb525f7894494f07df576b57933cc45bd6f1856764e5c1a1751d3d1800ba9123dd3d802a1e8c375cc0b
|
||||
|
@ -0,0 +1,28 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-ada/cbind/cbind-6.0.1.ebuild,v 1.1 2012/11/30 12:40:17 george Exp $
|
||||
|
||||
# !NOTE!
|
||||
# this is a utility, no libs generated, no reason to do the gnat.eclass dance
|
||||
# so, "inherit gnat" should not appear here!
|
||||
|
||||
DESCRIPTION="This tool is designed to aid in the creation of Ada bindings to C."
|
||||
SRC_URI="mirror://gentoo/${P}.tar.bz2"
|
||||
HOMEPAGE="http://www.rational.com/"
|
||||
LICENSE="GMGPL"
|
||||
|
||||
DEPEND="virtual/ada"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="~x86 ~amd64"
|
||||
IUSE=""
|
||||
|
||||
src_compile() {
|
||||
MAKEOPTS="${MAKEOPTS} -j1" emake || die
|
||||
}
|
||||
|
||||
src_install () {
|
||||
make PREFIX="${D}"/usr/ install || die
|
||||
dodoc README DOCS
|
||||
}
|
@ -1,2 +1,3 @@
|
||||
DIST tbb40_297oss_src.tgz 2097295 SHA256 2d1d10564e536c0ecf50d2db984f9fd9c615909bab13531936f0ca2c0e7cc2c2 SHA512 d41365eb13fdaab78fbdbc20d7d39681e3b6effc3e162c887dc2298307c1b7ad510133c1df50a458d6fd30f8b90f6af7be990180fd25695c2428d096097b9af5 WHIRLPOOL 05b471a23ea2f8c1f4f04bfe48abcf3156b06e5a2b405ae10f6767f10cc80268875802c1c4a140eaafdb17c44c102d6aff69c8296e650c6dbc42ea3487576e30
|
||||
DIST tbb41_20120718oss_src.tgz 2223581 SHA256 fb5c2082b6871eedc6c77ac7cec7d46f5ce7498b848f91808d954d93469115cb SHA512 3e7b2367db84c4c46dd2f7ecb1ac35068bd8ef8adf768ec11a5b37306c9e100e02d685c877521fbcc4928d612e7b2663574ba439f938011e6a0477de750d417a WHIRLPOOL 9b323f881d72940ae17ab42e6e8051dc2ecf704bce8d3da5ec4cb111bf432323232a1dacc62e4381977ac773bb14502f01261c8fcaff9aad465c296df6ab5595
|
||||
DIST tbb41_20121003oss_src.tgz 2250789 SHA256 5383727b9582a54cf4c4adbf22186b70e8eba276fcd3be81d746a937c5b47afc SHA512 fada6e32a09be2a151746caf3a15729c9ec6043b17e2f0aeb1bd903542310cdc6fe9ad85017ff5b2cfb16ae955c81c8b39ad8cf97f871bfcbd19d4948ef1d821 WHIRLPOOL 6c2a094e1dc6efed7189903bf8a6bbb8688ab1b15134c9f3c09fd5ed6a72315140505f5df410c89b65cd160a896222d71e01b3bfcbcd933281fb18a69eaf33f1
|
||||
|
@ -0,0 +1,112 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-cpp/tbb/tbb-4.1.20121003.ebuild,v 1.1 2012/11/30 20:37:31 bicatali Exp $
|
||||
|
||||
EAPI=4
|
||||
inherit eutils flag-o-matic multilib versionator toolchain-funcs
|
||||
|
||||
PV1="$(get_version_component_range 1)"
|
||||
PV2="$(get_version_component_range 2)"
|
||||
PV3="$(get_version_component_range 3)"
|
||||
MYP="${PN}${PV1}${PV2}_${PV3}oss"
|
||||
|
||||
DESCRIPTION="High level abstract threading library"
|
||||
HOMEPAGE="http://www.threadingbuildingblocks.org/"
|
||||
SRC_URI="http://threadingbuildingblocks.org/sites/default/files/software_releases/source/${MYP}_src.tgz"
|
||||
LICENSE="GPL-2-with-exceptions"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
|
||||
IUSE="debug doc examples"
|
||||
|
||||
DEPEND=""
|
||||
RDEPEND="${DEPEND}"
|
||||
S="${WORKDIR}/${MYP}"
|
||||
|
||||
src_prepare() {
|
||||
epatch "${FILESDIR}"/${PN}-4.0.297-underlinking.patch
|
||||
# use fully qualified gcc compilers. do not force march/mcpu
|
||||
# not tested with icc
|
||||
# order in sed expressions is important
|
||||
sed -i \
|
||||
-e "s/g++/$(tc-getCXX)/g" \
|
||||
-e "s/gcc/$(tc-getCC)/g" \
|
||||
-e 's/-m\(arch\|cpu\)=*[[:space:]]//g' \
|
||||
-e 's/-\(m\|-\)\(64\|32\)//g' \
|
||||
-e 's/-O2/$(CXXFLAGS)/g' \
|
||||
-e "/^ASM/s/as/$(tc-getAS)/g" \
|
||||
build/*.gcc.inc || die
|
||||
|
||||
find include -name \*.html -delete || die
|
||||
|
||||
# pc files are for debian and fedora compatibility
|
||||
# some deps use them
|
||||
cat <<-EOF > ${PN}.pc.template
|
||||
prefix=${EPREFIX}/usr
|
||||
libdir=\${prefix}/$(get_libdir)
|
||||
includedir=\${prefix}/include
|
||||
Name: ${PN}
|
||||
Description: ${DESCRIPTION}
|
||||
Version: ${PV}
|
||||
URL: ${HOMEPAGE}
|
||||
Cflags: -I\${includedir}
|
||||
EOF
|
||||
cp ${PN}.pc.template ${PN}.pc
|
||||
cat <<-EOF >> ${PN}.pc
|
||||
Libs: -L\${libdir} -ltbb
|
||||
Libs.private: -lm -lrt
|
||||
EOF
|
||||
cp ${PN}.pc.template ${PN}malloc.pc
|
||||
cat <<-EOF >> ${PN}malloc.pc
|
||||
Libs: -L\${libdir} -ltbbmalloc
|
||||
Libs.private: -lm -lrt
|
||||
EOF
|
||||
cp ${PN}.pc.template ${PN}malloc_proxy.pc
|
||||
cat <<-EOF >> ${PN}malloc_proxy.pc
|
||||
Libs: -L\${libdir} -ltbbmalloc_proxy
|
||||
Libs.private: -lrt
|
||||
Requires: tbbmalloc
|
||||
EOF
|
||||
use debug || sed -i -e '/_debug/d' Makefile
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
if [[ $(tc-getCXX) == *g++ ]]; then
|
||||
comp="gcc"
|
||||
elif [[ $(tc-getCXX) == *ic*c ]]; then
|
||||
comp="icc"
|
||||
else
|
||||
die "compiler $(tc-getCXX) not supported by build system"
|
||||
fi
|
||||
emake compiler=${comp} tbb tbbmalloc
|
||||
}
|
||||
|
||||
src_test() {
|
||||
append-cxxflags -fabi-version=4
|
||||
# avoid oversubscribing with -j1
|
||||
emake -j1 compiler=${comp} test
|
||||
}
|
||||
|
||||
src_install(){
|
||||
local l
|
||||
for l in $(find build -name lib\*.so.\*); do
|
||||
dolib.so ${l}
|
||||
local bl=$(basename ${l})
|
||||
dosym ${bl} /usr/$(get_libdir)/${bl%.*}
|
||||
done
|
||||
insinto /usr
|
||||
doins -r include
|
||||
|
||||
insinto /usr/$(get_libdir)/pkgconfig
|
||||
doins *.pc
|
||||
|
||||
dodoc README CHANGES doc/Release_Notes.txt
|
||||
use doc && dohtml -r doc/html/*
|
||||
|
||||
if use examples ; then
|
||||
insinto /usr/share/doc/${PF}/examples/build
|
||||
doins build/*.inc
|
||||
insinto /usr/share/doc/${PF}/examples
|
||||
doins -r examples
|
||||
fi
|
||||
}
|
@ -0,0 +1,329 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-lang/python/python-2.5.4-r5.ebuild,v 1.3 2012/12/01 09:56:06 mgorny Exp $
|
||||
|
||||
EAPI="1"
|
||||
|
||||
# Bootstrapping Python 2 requires Python 2.
|
||||
PYTHON_COMPAT=( python{2_5,2_6,2_7} )
|
||||
|
||||
inherit autotools eutils flag-o-matic multilib pax-utils python-any-r1 toolchain-funcs
|
||||
|
||||
MY_P="Python-${PV}"
|
||||
|
||||
PATCHSET_REVISION="3"
|
||||
|
||||
DESCRIPTION="An interpreted, interactive, object-oriented programming language"
|
||||
HOMEPAGE="http://www.python.org/"
|
||||
SRC_URI="http://www.python.org/ftp/python/${PV}/${MY_P}.tar.bz2
|
||||
mirror://gentoo/python-gentoo-patches-${PV}$([[ "${PATCHSET_REVISION}" != "0" ]] && echo "-r${PATCHSET_REVISION}").tar.bz2"
|
||||
|
||||
LICENSE="PSF-2.2"
|
||||
SLOT="2.5"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd"
|
||||
IUSE="-berkdb build doc elibc_uclibc examples gdbm ipv6 +ncurses +readline sqlite +ssl +threads tk +wide-unicode wininst +xml"
|
||||
|
||||
# NOTE: dev-python/{elementtree,celementtree,pysqlite}
|
||||
# do not conflict with the ones in python proper. - liquidx
|
||||
|
||||
RDEPEND=">=sys-libs/zlib-1.1.3
|
||||
virtual/libffi
|
||||
virtual/libintl
|
||||
!build? (
|
||||
berkdb? ( || (
|
||||
sys-libs/db:4.5
|
||||
sys-libs/db:4.4
|
||||
sys-libs/db:4.3
|
||||
sys-libs/db:4.2
|
||||
) )
|
||||
gdbm? ( sys-libs/gdbm )
|
||||
ncurses? (
|
||||
>=sys-libs/ncurses-5.2
|
||||
readline? ( >=sys-libs/readline-4.1 )
|
||||
)
|
||||
sqlite? ( >=dev-db/sqlite-3 )
|
||||
ssl? ( dev-libs/openssl )
|
||||
tk? ( >=dev-lang/tk-8.0 )
|
||||
xml? ( >=dev-libs/expat-2 )
|
||||
)
|
||||
doc? ( dev-python/python-docs:${SLOT} )"
|
||||
DEPEND="${RDEPEND}
|
||||
${PYTHON_DEPS}
|
||||
virtual/pkgconfig"
|
||||
RDEPEND+=" !build? ( app-misc/mime-types )"
|
||||
PDEPEND="app-admin/eselect-python
|
||||
app-admin/python-updater"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
pkg_setup() {
|
||||
if use berkdb; then
|
||||
ewarn "'bsddb' module is out-of-date and no longer maintained inside"
|
||||
ewarn "dev-lang/python. 'bsddb' and 'dbhash' modules have been additionally"
|
||||
ewarn "removed in Python 3. A maintained alternative of 'bsddb3' module"
|
||||
ewarn "is provided by dev-python/bsddb3."
|
||||
fi
|
||||
|
||||
python-any-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
unpack ${A}
|
||||
cd "${S}"
|
||||
|
||||
# Ensure that internal copies of expat, libffi and zlib are not used.
|
||||
rm -fr Modules/expat
|
||||
rm -fr Modules/_ctypes/libffi*
|
||||
rm -fr Modules/zlib
|
||||
|
||||
if tc-is-cross-compiler; then
|
||||
epatch "${FILESDIR}/python-2.5-cross-printf.patch"
|
||||
else
|
||||
rm "${WORKDIR}/${PV}"/*_all_crosscompile.patch
|
||||
fi
|
||||
|
||||
EPATCH_SUFFIX="patch" epatch "${WORKDIR}/${PV}"
|
||||
|
||||
sed -i -e "s:@@GENTOO_LIBDIR@@:$(get_libdir):g" \
|
||||
Lib/distutils/command/install.py \
|
||||
Lib/distutils/sysconfig.py \
|
||||
Lib/site.py \
|
||||
Makefile.pre.in \
|
||||
Modules/Setup.dist \
|
||||
Modules/getpath.c \
|
||||
setup.py || die "sed failed to replace @@GENTOO_LIBDIR@@"
|
||||
|
||||
# Fix os.utime() on hppa. utimes it not supported but unfortunately reported as working - gmsoft (22 May 04)
|
||||
# PLEASE LEAVE THIS FIX FOR NEXT VERSIONS AS IT'S A CRITICAL FIX !!!
|
||||
[[ "${ARCH}" == "hppa" ]] && sed -e "s/utimes //" -i "${S}/configure"
|
||||
|
||||
if ! use wininst; then
|
||||
# Remove Microsoft Windows executables.
|
||||
rm Lib/distutils/command/wininst-*.exe
|
||||
fi
|
||||
|
||||
# Linux-3 compat. Bug #374579 (upstream issue12571)
|
||||
cp -r "${S}/Lib/plat-linux2" "${S}/Lib/plat-linux3" || die
|
||||
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
# Disable extraneous modules with extra dependencies.
|
||||
if use build; then
|
||||
export PYTHON_DISABLE_MODULES="dbm _bsddb gdbm _curses _curses_panel readline _sqlite3 _tkinter pyexpat"
|
||||
export PYTHON_DISABLE_SSL="1"
|
||||
else
|
||||
# dbm module can be linked against berkdb or gdbm.
|
||||
# Defaults to gdbm when both are enabled, #204343.
|
||||
local disable
|
||||
use berkdb || use gdbm || disable+=" dbm"
|
||||
use berkdb || disable+=" _bsddb"
|
||||
use gdbm || disable+=" gdbm"
|
||||
use ncurses || disable+=" _curses _curses_panel"
|
||||
use readline || disable+=" readline"
|
||||
use sqlite || disable+=" _sqlite3"
|
||||
use ssl || export PYTHON_DISABLE_SSL="1"
|
||||
use tk || disable+=" _tkinter"
|
||||
use xml || disable+=" pyexpat"
|
||||
export PYTHON_DISABLE_MODULES="${disable}"
|
||||
|
||||
if ! use xml; then
|
||||
ewarn "You have configured Python without XML support."
|
||||
ewarn "This is NOT a recommended configuration as you"
|
||||
ewarn "may face problems parsing any XML documents."
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -n "${PYTHON_DISABLE_MODULES}" ]]; then
|
||||
einfo "Disabled modules: ${PYTHON_DISABLE_MODULES}"
|
||||
fi
|
||||
|
||||
if [[ "$(gcc-major-version)" -ge 4 ]]; then
|
||||
append-flags -fwrapv
|
||||
fi
|
||||
|
||||
export OPT="${CFLAGS}"
|
||||
|
||||
filter-flags -malign-double
|
||||
|
||||
[[ "${ARCH}" == "alpha" ]] && append-flags -fPIC
|
||||
|
||||
# https://bugs.gentoo.org/show_bug.cgi?id=50309
|
||||
if is-flagq -O3; then
|
||||
is-flagq -fstack-protector-all && replace-flags -O3 -O2
|
||||
use hardened && replace-flags -O3 -O2
|
||||
fi
|
||||
|
||||
if tc-is-cross-compiler; then
|
||||
OPT="-O1" CFLAGS="" LDFLAGS="" CC="" \
|
||||
./configure --{build,host}=${CBUILD} || die "cross-configure failed"
|
||||
emake python Parser/pgen || die "cross-make failed"
|
||||
mv python hostpython
|
||||
mv Parser/pgen Parser/hostpgen
|
||||
make distclean
|
||||
sed -i \
|
||||
-e "/^HOSTPYTHON/s:=.*:=./hostpython:" \
|
||||
-e "/^HOSTPGEN/s:=.*:=./Parser/hostpgen:" \
|
||||
Makefile.pre.in || die "sed failed"
|
||||
fi
|
||||
|
||||
# Export CXX so it ends up in /usr/lib/python2.X/config/Makefile.
|
||||
tc-export CXX
|
||||
# The configure script fails to use pkg-config correctly.
|
||||
# http://bugs.python.org/issue15506
|
||||
export ac_cv_path_PKG_CONFIG=$(tc-getPKG_CONFIG)
|
||||
|
||||
# Set LDFLAGS so we link modules with -lpython2.5 correctly.
|
||||
# Needed on FreeBSD unless Python 2.5 is already installed.
|
||||
# Please query BSD team before removing this!
|
||||
append-ldflags "-L."
|
||||
|
||||
econf \
|
||||
--with-fpectl \
|
||||
--enable-shared \
|
||||
$(use_enable ipv6) \
|
||||
$(use_with threads) \
|
||||
$(use wide-unicode && echo "--enable-unicode=ucs4" || echo "--enable-unicode=ucs2") \
|
||||
--infodir='${prefix}/share/info' \
|
||||
--mandir='${prefix}/share/man' \
|
||||
--with-libc="" \
|
||||
--with-system-ffi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
src_configure
|
||||
emake || die "emake failed"
|
||||
}
|
||||
|
||||
src_test() {
|
||||
# Tests will not work when cross compiling.
|
||||
if tc-is-cross-compiler; then
|
||||
elog "Disabling tests due to crosscompiling."
|
||||
return
|
||||
fi
|
||||
|
||||
# Skip failing tests.
|
||||
local skip_tests="distutils global mimetools minidom mmap posix pyexpat sax strptime subprocess syntax tcl time urllib urllib2 xml_etree"
|
||||
|
||||
# test_ctypes fails with PAX kernel (bug #234498).
|
||||
host-is-pax && skip_tests+=" ctypes"
|
||||
|
||||
for test in ${skip_tests}; do
|
||||
mv "${S}/Lib/test/test_${test}.py" "${T}"
|
||||
done
|
||||
|
||||
# Redirect stdin from /dev/tty as a workaround for bug #248081.
|
||||
# Rerun failed tests in verbose mode (regrtest -w).
|
||||
EXTRATESTOPTS="-w" emake test < /dev/tty
|
||||
local result="$?"
|
||||
|
||||
for test in ${skip_tests}; do
|
||||
mv "${T}/test_${test}.py" "${S}/Lib/test/test_${test}.py"
|
||||
done
|
||||
|
||||
elog "The following tests have been skipped:"
|
||||
for test in ${skip_tests}; do
|
||||
elog "test_${test}.py"
|
||||
done
|
||||
|
||||
elog "If you would like to run them, you may:"
|
||||
elog "cd '${EPREFIX}/usr/$(get_libdir)/python${SLOT}/test'"
|
||||
elog "and run the tests separately."
|
||||
|
||||
if [[ "${result}" -ne 0 ]]; then
|
||||
die "emake test failed"
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
[[ -z "${ED}" ]] && ED="${D%/}${EPREFIX}/"
|
||||
|
||||
local libdir=${ED}/usr/$(get_libdir)/python${SLOT}
|
||||
|
||||
emake DESTDIR="${D}" altinstall maninstall || die "emake altinstall maninstall failed"
|
||||
|
||||
mv "${ED}usr/bin/python${SLOT}-config" "${ED}usr/bin/python-config-${SLOT}"
|
||||
|
||||
# Fix collisions between different slots of Python.
|
||||
mv "${ED}usr/bin/pydoc" "${ED}usr/bin/pydoc${SLOT}"
|
||||
mv "${ED}usr/bin/idle" "${ED}usr/bin/idle${SLOT}"
|
||||
mv "${ED}usr/share/man/man1/python.1" "${ED}usr/share/man/man1/python${SLOT}.1"
|
||||
rm -f "${ED}usr/bin/smtpd.py"
|
||||
|
||||
# Fix the OPT variable so that it doesn't have any flags listed in it.
|
||||
# Prevents the problem with compiling things with conflicting flags later.
|
||||
sed -e "s:^OPT=.*:OPT=\t\t-DNDEBUG:" -i "${libdir}/config/Makefile"
|
||||
|
||||
if use build; then
|
||||
rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{bsddb,idlelib,lib-tk,sqlite3,test}
|
||||
else
|
||||
use elibc_uclibc && rm -fr "${libdir}/"{bsddb/test,test}
|
||||
use berkdb || rm -fr "${libdir}/"{bsddb,test/test_bsddb*}
|
||||
use sqlite || rm -fr "${libdir}/"{sqlite3,test/test_sqlite*}
|
||||
use tk || rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{idlelib,lib-tk}
|
||||
fi
|
||||
|
||||
dodoc Misc/{ACKS,HISTORY,NEWS} || die "dodoc failed"
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}/examples
|
||||
doins -r "${S}/Tools" || die "doins failed"
|
||||
fi
|
||||
|
||||
newconfd "${FILESDIR}/pydoc.conf" pydoc-${SLOT} || die "newconfd failed"
|
||||
newinitd "${FILESDIR}/pydoc.init" pydoc-${SLOT} || die "newinitd failed"
|
||||
sed \
|
||||
-e "s:@PYDOC_PORT_VARIABLE@:PYDOC${SLOT/./_}_PORT:" \
|
||||
-e "s:@PYDOC@:pydoc${SLOT}:" \
|
||||
-i "${ED}etc/conf.d/pydoc-${SLOT}" "${ED}etc/init.d/pydoc-${SLOT}" || die "sed failed"
|
||||
|
||||
# for python-exec
|
||||
python_export python${SLOT} EPYTHON PYTHON PYTHON_SITEDIR
|
||||
|
||||
# if not using a cross-compiler, use the fresh binary
|
||||
if ! tc-is-cross-compiler; then
|
||||
local PYTHON=./python \
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH+${LD_LIBRARY_PATH}:}.
|
||||
export LD_LIBRARY_PATH
|
||||
fi
|
||||
|
||||
echo "EPYTHON='${EPYTHON}'" > epython.py
|
||||
python_domodule epython.py
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
if has_version "<${CATEGORY}/${PN}-${SLOT}" && ! has_version "${CATEGORY}/${PN}:2.5" && ! has_version "${CATEGORY}/${PN}:2.6" && ! has_version "${CATEGORY}/${PN}:2.7"; then
|
||||
python_updater_warning="1"
|
||||
fi
|
||||
}
|
||||
|
||||
eselect_python_update() {
|
||||
local eselect_python_options
|
||||
[[ "$(eselect python show)" == "python2."* ]] && eselect_python_options="--python2"
|
||||
|
||||
# Create python2 symlink.
|
||||
eselect python update --python2 > /dev/null
|
||||
|
||||
eselect python update ${eselect_python_options}
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
eselect_python_update
|
||||
|
||||
if [[ "${python_updater_warning}" == "1" ]]; then
|
||||
ewarn
|
||||
ewarn "\e[1;31m************************************************************************\e[0m"
|
||||
ewarn
|
||||
ewarn "You have just upgraded from an older version of Python."
|
||||
ewarn "You should run 'python-updater \${options}' to rebuild Python modules."
|
||||
ewarn
|
||||
ewarn "\e[1;31m************************************************************************\e[0m"
|
||||
ewarn
|
||||
ebeep 12
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
eselect_python_update
|
||||
}
|
@ -0,0 +1,322 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-lang/python/python-2.6.8-r1.ebuild,v 1.3 2012/12/01 09:56:06 mgorny Exp $
|
||||
|
||||
EAPI="2"
|
||||
WANT_AUTOMAKE="none"
|
||||
WANT_LIBTOOL="none"
|
||||
|
||||
# Bootstrapping Python 2 requires Python 2.
|
||||
PYTHON_COMPAT=( python{2_5,2_6,2_7} )
|
||||
|
||||
inherit autotools eutils flag-o-matic multilib pax-utils python-any-r1 toolchain-funcs
|
||||
|
||||
MY_P="Python-${PV}"
|
||||
PATCHSET_REVISION="0"
|
||||
|
||||
DESCRIPTION="An interpreted, interactive, object-oriented programming language"
|
||||
HOMEPAGE="http://www.python.org/"
|
||||
SRC_URI="http://www.python.org/ftp/python/${PV}/${MY_P}.tar.bz2
|
||||
mirror://gentoo/python-gentoo-patches-${PV}-${PATCHSET_REVISION}.tar.bz2"
|
||||
|
||||
LICENSE="PSF-2"
|
||||
SLOT="2.6"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd"
|
||||
IUSE="-berkdb build doc elibc_uclibc examples gdbm ipv6 +ncurses +readline sqlite +ssl +threads tk +wide-unicode wininst +xml"
|
||||
|
||||
RDEPEND="app-arch/bzip2
|
||||
>=sys-libs/zlib-1.1.3
|
||||
virtual/libffi
|
||||
virtual/libintl
|
||||
!build? (
|
||||
berkdb? ( || (
|
||||
sys-libs/db:4.7
|
||||
sys-libs/db:4.6
|
||||
sys-libs/db:4.5
|
||||
sys-libs/db:4.4
|
||||
sys-libs/db:4.3
|
||||
sys-libs/db:4.2
|
||||
) )
|
||||
gdbm? ( sys-libs/gdbm[berkdb] )
|
||||
ncurses? (
|
||||
>=sys-libs/ncurses-5.2
|
||||
readline? ( >=sys-libs/readline-4.1 )
|
||||
)
|
||||
sqlite? ( >=dev-db/sqlite-3.3.3:3 )
|
||||
ssl? ( dev-libs/openssl )
|
||||
tk? (
|
||||
>=dev-lang/tk-8.0
|
||||
dev-tcltk/blt
|
||||
)
|
||||
xml? ( >=dev-libs/expat-2.1 )
|
||||
)
|
||||
!!<sys-apps/portage-2.1.9"
|
||||
DEPEND="${RDEPEND}
|
||||
${PYTHON_DEPS}
|
||||
virtual/pkgconfig
|
||||
>=sys-devel/autoconf-2.61
|
||||
!sys-devel/gcc[libffi]"
|
||||
RDEPEND+=" !build? ( app-misc/mime-types )
|
||||
doc? ( dev-python/python-docs:${SLOT} )"
|
||||
PDEPEND="app-admin/eselect-python
|
||||
app-admin/python-updater"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
pkg_setup() {
|
||||
if use berkdb; then
|
||||
ewarn "'bsddb' module is out-of-date and no longer maintained inside"
|
||||
ewarn "dev-lang/python. 'bsddb' and 'dbhash' modules have been additionally"
|
||||
ewarn "removed in Python 3. A maintained alternative of 'bsddb3' module"
|
||||
ewarn "is provided by dev-python/bsddb3."
|
||||
else
|
||||
if has_version "=${CATEGORY}/${PN}-${PV%%.*}*[berkdb]"; then
|
||||
ewarn "You are migrating from =${CATEGORY}/${PN}-${PV%%.*}*[berkdb]"
|
||||
ewarn "to =${CATEGORY}/${PN}-${PV%%.*}*[-berkdb]."
|
||||
ewarn "You might need to migrate your databases."
|
||||
fi
|
||||
fi
|
||||
|
||||
python-any-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Ensure that internal copies of expat, libffi and zlib are not used.
|
||||
rm -fr Modules/expat
|
||||
rm -fr Modules/_ctypes/libffi*
|
||||
rm -fr Modules/zlib
|
||||
|
||||
local excluded_patches
|
||||
if ! tc-is-cross-compiler; then
|
||||
excluded_patches="*_all_crosscompile.patch"
|
||||
fi
|
||||
|
||||
EPATCH_EXCLUDE="${excluded_patches}" EPATCH_SUFFIX="patch" \
|
||||
epatch "${WORKDIR}/${PV}-${PATCHSET_REVISION}"
|
||||
|
||||
sed -i -e "s:@@GENTOO_LIBDIR@@:$(get_libdir):g" \
|
||||
Lib/distutils/command/install.py \
|
||||
Lib/distutils/sysconfig.py \
|
||||
Lib/site.py \
|
||||
Makefile.pre.in \
|
||||
Modules/Setup.dist \
|
||||
Modules/getpath.c \
|
||||
setup.py || die "sed failed to replace @@GENTOO_LIBDIR@@"
|
||||
|
||||
eautoconf
|
||||
eautoheader
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
if use build; then
|
||||
# Disable extraneous modules with extra dependencies.
|
||||
export PYTHON_DISABLE_MODULES="dbm _bsddb gdbm _curses _curses_panel readline _sqlite3 _tkinter _elementtree pyexpat"
|
||||
export PYTHON_DISABLE_SSL="1"
|
||||
else
|
||||
# dbm module can be linked against berkdb or gdbm.
|
||||
# Defaults to gdbm when both are enabled, #204343.
|
||||
local disable
|
||||
use berkdb || use gdbm || disable+=" dbm"
|
||||
use berkdb || disable+=" _bsddb"
|
||||
use gdbm || disable+=" gdbm"
|
||||
use ncurses || disable+=" _curses _curses_panel"
|
||||
use readline || disable+=" readline"
|
||||
use sqlite || disable+=" _sqlite3"
|
||||
use ssl || export PYTHON_DISABLE_SSL="1"
|
||||
use tk || disable+=" _tkinter"
|
||||
use xml || disable+=" _elementtree pyexpat" # _elementtree uses pyexpat.
|
||||
export PYTHON_DISABLE_MODULES="${disable}"
|
||||
|
||||
if ! use xml; then
|
||||
ewarn "You have configured Python without XML support."
|
||||
ewarn "This is NOT a recommended configuration as you"
|
||||
ewarn "may face problems parsing any XML documents."
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -n "${PYTHON_DISABLE_MODULES}" ]]; then
|
||||
einfo "Disabled modules: ${PYTHON_DISABLE_MODULES}"
|
||||
fi
|
||||
|
||||
if [[ "$(gcc-major-version)" -ge 4 ]]; then
|
||||
append-flags -fwrapv
|
||||
fi
|
||||
|
||||
filter-flags -malign-double
|
||||
|
||||
[[ "${ARCH}" == "alpha" ]] && append-flags -fPIC
|
||||
|
||||
# https://bugs.gentoo.org/show_bug.cgi?id=50309
|
||||
if is-flagq -O3; then
|
||||
is-flagq -fstack-protector-all && replace-flags -O3 -O2
|
||||
use hardened && replace-flags -O3 -O2
|
||||
fi
|
||||
|
||||
if tc-is-cross-compiler; then
|
||||
OPT="-O1" CFLAGS="" LDFLAGS="" CC="" \
|
||||
./configure --{build,host}=${CBUILD} || die "cross-configure failed"
|
||||
emake python Parser/pgen || die "cross-make failed"
|
||||
mv python hostpython
|
||||
mv Parser/pgen Parser/hostpgen
|
||||
make distclean
|
||||
sed -i \
|
||||
-e "/^HOSTPYTHON/s:=.*:=./hostpython:" \
|
||||
-e "/^HOSTPGEN/s:=.*:=./Parser/hostpgen:" \
|
||||
Makefile.pre.in || die "sed failed"
|
||||
fi
|
||||
|
||||
# Export CXX so it ends up in /usr/lib/python2.X/config/Makefile.
|
||||
tc-export CXX
|
||||
# The configure script fails to use pkg-config correctly.
|
||||
# http://bugs.python.org/issue15506
|
||||
export ac_cv_path_PKG_CONFIG=$(tc-getPKG_CONFIG)
|
||||
|
||||
# Set LDFLAGS so we link modules with -lpython2.6 correctly.
|
||||
# Needed on FreeBSD unless Python 2.6 is already installed.
|
||||
# Please query BSD team before removing this!
|
||||
append-ldflags "-L."
|
||||
|
||||
OPT="" econf \
|
||||
--with-fpectl \
|
||||
--enable-shared \
|
||||
$(use_enable ipv6) \
|
||||
$(use_with threads) \
|
||||
$(use wide-unicode && echo "--enable-unicode=ucs4" || echo "--enable-unicode=ucs2") \
|
||||
--infodir='${prefix}/share/info' \
|
||||
--mandir='${prefix}/share/man' \
|
||||
--with-libc="" \
|
||||
--with-system-ffi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
default
|
||||
|
||||
# Work around bug 329499. See also bug 413751.
|
||||
pax-mark m python
|
||||
}
|
||||
|
||||
src_test() {
|
||||
# Tests will not work when cross compiling.
|
||||
if tc-is-cross-compiler; then
|
||||
elog "Disabling tests due to crosscompiling."
|
||||
return
|
||||
fi
|
||||
|
||||
# Skip failing tests.
|
||||
local skipped_tests="distutils tcl"
|
||||
|
||||
for test in ${skipped_tests}; do
|
||||
mv Lib/test/test_${test}.py "${T}"
|
||||
done
|
||||
|
||||
# Rerun failed tests in verbose mode (regrtest -w).
|
||||
emake test EXTRATESTOPTS="-w" < /dev/tty
|
||||
local result="$?"
|
||||
|
||||
for test in ${skipped_tests}; do
|
||||
mv "${T}/test_${test}.py" Lib/test
|
||||
done
|
||||
|
||||
elog "The following tests have been skipped:"
|
||||
for test in ${skipped_tests}; do
|
||||
elog "test_${test}.py"
|
||||
done
|
||||
|
||||
elog "If you would like to run them, you may:"
|
||||
elog "cd '${EPREFIX}/usr/$(get_libdir)/python${SLOT}/test'"
|
||||
elog "and run the tests separately."
|
||||
|
||||
python_disable_pyc
|
||||
|
||||
if [[ "${result}" -ne 0 ]]; then
|
||||
die "emake test failed"
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
[[ -z "${ED}" ]] && ED="${D%/}${EPREFIX}/"
|
||||
|
||||
local libdir=${ED}/usr/$(get_libdir)/python${SLOT}
|
||||
|
||||
emake DESTDIR="${D}" altinstall maninstall || die "emake altinstall maninstall failed"
|
||||
|
||||
mv "${ED}usr/bin/python${SLOT}-config" "${ED}usr/bin/python-config-${SLOT}"
|
||||
|
||||
# Fix collisions between different slots of Python.
|
||||
mv "${ED}usr/bin/2to3" "${ED}usr/bin/2to3-${SLOT}"
|
||||
mv "${ED}usr/bin/pydoc" "${ED}usr/bin/pydoc${SLOT}"
|
||||
mv "${ED}usr/bin/idle" "${ED}usr/bin/idle${SLOT}"
|
||||
mv "${ED}usr/share/man/man1/python.1" "${ED}usr/share/man/man1/python${SLOT}.1"
|
||||
rm -f "${ED}usr/bin/smtpd.py"
|
||||
|
||||
if use build; then
|
||||
rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{bsddb,dbhash.py,idlelib,lib-tk,sqlite3,test}
|
||||
else
|
||||
use elibc_uclibc && rm -fr "${libdir}/"{bsddb/test,test}
|
||||
use berkdb || rm -fr "${libdir}/"{bsddb,dbhash.py,test/test_bsddb*}
|
||||
use sqlite || rm -fr "${libdir}/"{sqlite3,test/test_sqlite*}
|
||||
use tk || rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{idlelib,lib-tk}
|
||||
fi
|
||||
|
||||
use threads || rm -fr "${libdir}/multiprocessing"
|
||||
use wininst || rm -f "${libdir})/distutils/command/"wininst-*.exe
|
||||
|
||||
dodoc Misc/{ACKS,HISTORY,NEWS} || die "dodoc failed"
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}/examples
|
||||
doins -r Tools || die "doins failed"
|
||||
fi
|
||||
|
||||
newconfd "${FILESDIR}/pydoc.conf" pydoc-${SLOT} || die "newconfd failed"
|
||||
newinitd "${FILESDIR}/pydoc.init" pydoc-${SLOT} || die "newinitd failed"
|
||||
sed \
|
||||
-e "s:@PYDOC_PORT_VARIABLE@:PYDOC${SLOT/./_}_PORT:" \
|
||||
-e "s:@PYDOC@:pydoc${SLOT}:" \
|
||||
-i "${ED}etc/conf.d/pydoc-${SLOT}" "${ED}etc/init.d/pydoc-${SLOT}" || die "sed failed"
|
||||
|
||||
# for python-exec
|
||||
python_export python${SLOT} EPYTHON PYTHON PYTHON_SITEDIR
|
||||
|
||||
# if not using a cross-compiler, use the fresh binary
|
||||
if ! tc-is-cross-compiler; then
|
||||
local PYTHON=./python \
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH+${LD_LIBRARY_PATH}:}.
|
||||
export LD_LIBRARY_PATH
|
||||
fi
|
||||
|
||||
echo "EPYTHON='${EPYTHON}'" > epython.py
|
||||
python_domodule epython.py
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
if has_version "<${CATEGORY}/${PN}-${SLOT}" && ! has_version "${CATEGORY}/${PN}:2.6" && ! has_version "${CATEGORY}/${PN}:2.7"; then
|
||||
python_updater_warning="1"
|
||||
fi
|
||||
}
|
||||
|
||||
eselect_python_update() {
|
||||
[[ -z "${EROOT}" || (! -d "${EROOT}" && -d "${ROOT}") ]] && EROOT="${ROOT%/}${EPREFIX}/"
|
||||
|
||||
if [[ -z "$(eselect python show)" || ! -f "${EROOT}usr/bin/$(eselect python show)" ]]; then
|
||||
eselect python update
|
||||
fi
|
||||
|
||||
if [[ -z "$(eselect python show --python${PV%%.*})" || ! -f "${EROOT}usr/bin/$(eselect python show --python${PV%%.*})" ]]; then
|
||||
eselect python update --python${PV%%.*}
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
eselect_python_update
|
||||
|
||||
if [[ "${python_updater_warning}" == "1" ]]; then
|
||||
ewarn "You have just upgraded from an older version of Python."
|
||||
ewarn "You should switch active version of Python ${PV%%.*} and run"
|
||||
ewarn "'python-updater [options]' to rebuild Python modules."
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
eselect_python_update
|
||||
}
|
@ -0,0 +1,337 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-lang/python/python-2.7.3-r3.ebuild,v 1.3 2012/12/01 09:56:06 mgorny Exp $
|
||||
|
||||
EAPI="2"
|
||||
WANT_AUTOMAKE="none"
|
||||
WANT_LIBTOOL="none"
|
||||
|
||||
# Bootstrapping Python 2 requires Python 2.
|
||||
PYTHON_COMPAT=( python{2_5,2_6,2_7} )
|
||||
|
||||
inherit autotools eutils flag-o-matic multilib pax-utils python-any-r1 toolchain-funcs
|
||||
|
||||
MY_P="Python-${PV}"
|
||||
PATCHSET_REVISION="1"
|
||||
|
||||
DESCRIPTION="An interpreted, interactive, object-oriented programming language"
|
||||
HOMEPAGE="http://www.python.org/"
|
||||
SRC_URI="http://www.python.org/ftp/python/${PV}/${MY_P}.tar.bz2
|
||||
mirror://gentoo/python-gentoo-patches-${PV}-${PATCHSET_REVISION}.tar.bz2"
|
||||
|
||||
LICENSE="PSF-2"
|
||||
SLOT="2.7"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
|
||||
IUSE="-berkdb build doc elibc_uclibc examples gdbm ipv6 +ncurses +readline sqlite +ssl +threads tk +wide-unicode wininst +xml"
|
||||
|
||||
RDEPEND="app-arch/bzip2
|
||||
>=sys-libs/zlib-1.1.3
|
||||
virtual/libffi
|
||||
virtual/libintl
|
||||
!build? (
|
||||
berkdb? ( || (
|
||||
sys-libs/db:4.8
|
||||
sys-libs/db:4.7
|
||||
sys-libs/db:4.6
|
||||
sys-libs/db:4.5
|
||||
sys-libs/db:4.4
|
||||
sys-libs/db:4.3
|
||||
sys-libs/db:4.2
|
||||
) )
|
||||
gdbm? ( sys-libs/gdbm[berkdb] )
|
||||
ncurses? (
|
||||
>=sys-libs/ncurses-5.2
|
||||
readline? ( >=sys-libs/readline-4.1 )
|
||||
)
|
||||
sqlite? ( >=dev-db/sqlite-3.3.8:3[extensions] )
|
||||
ssl? ( dev-libs/openssl )
|
||||
tk? (
|
||||
>=dev-lang/tk-8.0
|
||||
dev-tcltk/blt
|
||||
)
|
||||
xml? ( >=dev-libs/expat-2.1 )
|
||||
)
|
||||
!!<sys-apps/portage-2.1.9"
|
||||
DEPEND="${RDEPEND}
|
||||
${PYTHON_DEPS}
|
||||
virtual/pkgconfig
|
||||
>=sys-devel/autoconf-2.65
|
||||
!sys-devel/gcc[libffi]"
|
||||
RDEPEND+=" !build? ( app-misc/mime-types )
|
||||
doc? ( dev-python/python-docs:${SLOT} )"
|
||||
PDEPEND="app-admin/eselect-python
|
||||
app-admin/python-updater"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
pkg_setup() {
|
||||
if use berkdb; then
|
||||
ewarn "'bsddb' module is out-of-date and no longer maintained inside"
|
||||
ewarn "dev-lang/python. 'bsddb' and 'dbhash' modules have been additionally"
|
||||
ewarn "removed in Python 3. A maintained alternative of 'bsddb3' module"
|
||||
ewarn "is provided by dev-python/bsddb3."
|
||||
else
|
||||
if has_version "=${CATEGORY}/${PN}-${PV%%.*}*[berkdb]"; then
|
||||
ewarn "You are migrating from =${CATEGORY}/${PN}-${PV%%.*}*[berkdb]"
|
||||
ewarn "to =${CATEGORY}/${PN}-${PV%%.*}*[-berkdb]."
|
||||
ewarn "You might need to migrate your databases."
|
||||
fi
|
||||
fi
|
||||
|
||||
python-any-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Ensure that internal copies of expat, libffi and zlib are not used.
|
||||
rm -fr Modules/expat
|
||||
rm -fr Modules/_ctypes/libffi*
|
||||
rm -fr Modules/zlib
|
||||
|
||||
local excluded_patches
|
||||
if ! tc-is-cross-compiler; then
|
||||
excluded_patches="*_all_crosscompile.patch"
|
||||
fi
|
||||
|
||||
EPATCH_EXCLUDE="${excluded_patches}" EPATCH_SUFFIX="patch" \
|
||||
epatch "${WORKDIR}/${PV}-${PATCHSET_REVISION}"
|
||||
|
||||
sed -i -e "s:@@GENTOO_LIBDIR@@:$(get_libdir):g" \
|
||||
Lib/distutils/command/install.py \
|
||||
Lib/distutils/sysconfig.py \
|
||||
Lib/site.py \
|
||||
Lib/sysconfig.py \
|
||||
Lib/test/test_site.py \
|
||||
Makefile.pre.in \
|
||||
Modules/Setup.dist \
|
||||
Modules/getpath.c \
|
||||
setup.py || die "sed failed to replace @@GENTOO_LIBDIR@@"
|
||||
|
||||
eautoconf
|
||||
eautoheader
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
if use build; then
|
||||
# Disable extraneous modules with extra dependencies.
|
||||
export PYTHON_DISABLE_MODULES="dbm _bsddb gdbm _curses _curses_panel readline _sqlite3 _tkinter _elementtree pyexpat"
|
||||
export PYTHON_DISABLE_SSL="1"
|
||||
else
|
||||
# dbm module can be linked against berkdb or gdbm.
|
||||
# Defaults to gdbm when both are enabled, #204343.
|
||||
local disable
|
||||
use berkdb || use gdbm || disable+=" dbm"
|
||||
use berkdb || disable+=" _bsddb"
|
||||
use gdbm || disable+=" gdbm"
|
||||
use ncurses || disable+=" _curses _curses_panel"
|
||||
use readline || disable+=" readline"
|
||||
use sqlite || disable+=" _sqlite3"
|
||||
use ssl || export PYTHON_DISABLE_SSL="1"
|
||||
use tk || disable+=" _tkinter"
|
||||
use xml || disable+=" _elementtree pyexpat" # _elementtree uses pyexpat.
|
||||
export PYTHON_DISABLE_MODULES="${disable}"
|
||||
|
||||
if ! use xml; then
|
||||
ewarn "You have configured Python without XML support."
|
||||
ewarn "This is NOT a recommended configuration as you"
|
||||
ewarn "may face problems parsing any XML documents."
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -n "${PYTHON_DISABLE_MODULES}" ]]; then
|
||||
einfo "Disabled modules: ${PYTHON_DISABLE_MODULES}"
|
||||
fi
|
||||
|
||||
if [[ "$(gcc-major-version)" -ge 4 ]]; then
|
||||
append-flags -fwrapv
|
||||
fi
|
||||
|
||||
filter-flags -malign-double
|
||||
|
||||
[[ "${ARCH}" == "alpha" ]] && append-flags -fPIC
|
||||
|
||||
# https://bugs.gentoo.org/show_bug.cgi?id=50309
|
||||
if is-flagq -O3; then
|
||||
is-flagq -fstack-protector-all && replace-flags -O3 -O2
|
||||
use hardened && replace-flags -O3 -O2
|
||||
fi
|
||||
|
||||
if tc-is-cross-compiler; then
|
||||
OPT="-O1" CFLAGS="" LDFLAGS="" CC="" \
|
||||
./configure --{build,host}=${CBUILD} || die "cross-configure failed"
|
||||
emake python Parser/pgen || die "cross-make failed"
|
||||
mv python hostpython
|
||||
mv Parser/pgen Parser/hostpgen
|
||||
make distclean
|
||||
sed -i \
|
||||
-e "/^HOSTPYTHON/s:=.*:=./hostpython:" \
|
||||
-e "/^HOSTPGEN/s:=.*:=./Parser/hostpgen:" \
|
||||
Makefile.pre.in || die "sed failed"
|
||||
fi
|
||||
|
||||
# Export CXX so it ends up in /usr/lib/python2.X/config/Makefile.
|
||||
tc-export CXX
|
||||
# The configure script fails to use pkg-config correctly.
|
||||
# http://bugs.python.org/issue15506
|
||||
export ac_cv_path_PKG_CONFIG=$(tc-getPKG_CONFIG)
|
||||
|
||||
# Set LDFLAGS so we link modules with -lpython2.7 correctly.
|
||||
# Needed on FreeBSD unless Python 2.7 is already installed.
|
||||
# Please query BSD team before removing this!
|
||||
append-ldflags "-L."
|
||||
|
||||
local dbmliborder
|
||||
if use gdbm; then
|
||||
dbmliborder+="${dbmliborder:+:}gdbm"
|
||||
fi
|
||||
if use berkdb; then
|
||||
dbmliborder+="${dbmliborder:+:}bdb"
|
||||
fi
|
||||
|
||||
OPT="" econf \
|
||||
--with-fpectl \
|
||||
--enable-shared \
|
||||
$(use_enable ipv6) \
|
||||
$(use_with threads) \
|
||||
$(use wide-unicode && echo "--enable-unicode=ucs4" || echo "--enable-unicode=ucs2") \
|
||||
--infodir='${prefix}/share/info' \
|
||||
--mandir='${prefix}/share/man' \
|
||||
--with-dbmliborder="${dbmliborder}" \
|
||||
--with-libc="" \
|
||||
--enable-loadable-sqlite-extensions \
|
||||
--with-system-expat \
|
||||
--with-system-ffi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
default
|
||||
|
||||
# Work around bug 329499. See also bug 413751.
|
||||
pax-mark m python
|
||||
}
|
||||
|
||||
src_test() {
|
||||
# Tests will not work when cross compiling.
|
||||
if tc-is-cross-compiler; then
|
||||
elog "Disabling tests due to crosscompiling."
|
||||
return
|
||||
fi
|
||||
|
||||
# Skip failing tests.
|
||||
local skipped_tests="distutils gdb"
|
||||
|
||||
for test in ${skipped_tests}; do
|
||||
mv Lib/test/test_${test}.py "${T}"
|
||||
done
|
||||
|
||||
# Rerun failed tests in verbose mode (regrtest -w).
|
||||
emake test EXTRATESTOPTS="-w" < /dev/tty
|
||||
local result="$?"
|
||||
|
||||
for test in ${skipped_tests}; do
|
||||
mv "${T}/test_${test}.py" Lib/test
|
||||
done
|
||||
|
||||
elog "The following tests have been skipped:"
|
||||
for test in ${skipped_tests}; do
|
||||
elog "test_${test}.py"
|
||||
done
|
||||
|
||||
elog "If you would like to run them, you may:"
|
||||
elog "cd '${EPREFIX}/usr/$(get_libdir)/python${SLOT}/test'"
|
||||
elog "and run the tests separately."
|
||||
|
||||
python_disable_pyc
|
||||
|
||||
if [[ "${result}" -ne 0 ]]; then
|
||||
die "emake test failed"
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
[[ -z "${ED}" ]] && ED="${D%/}${EPREFIX}/"
|
||||
|
||||
local libdir=${ED}/usr/$(get_libdir)/python${SLOT}
|
||||
|
||||
emake DESTDIR="${D}" altinstall maninstall || die "emake altinstall maninstall failed"
|
||||
|
||||
sed -e "s/\(LDFLAGS=\).*/\1/" -i "${libdir}/config/Makefile" || die "sed failed"
|
||||
|
||||
mv "${ED}usr/bin/python${SLOT}-config" "${ED}usr/bin/python-config-${SLOT}"
|
||||
|
||||
# Fix collisions between different slots of Python.
|
||||
mv "${ED}usr/bin/2to3" "${ED}usr/bin/2to3-${SLOT}"
|
||||
mv "${ED}usr/bin/pydoc" "${ED}usr/bin/pydoc${SLOT}"
|
||||
mv "${ED}usr/bin/idle" "${ED}usr/bin/idle${SLOT}"
|
||||
rm -f "${ED}usr/bin/smtpd.py"
|
||||
|
||||
if use build; then
|
||||
rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{bsddb,dbhash.py,idlelib,lib-tk,sqlite3,test}
|
||||
else
|
||||
use elibc_uclibc && rm -fr "${libdir}/"{bsddb/test,test}
|
||||
use berkdb || rm -fr "${libdir}/"{bsddb,dbhash.py,test/test_bsddb*}
|
||||
use sqlite || rm -fr "${libdir}/"{sqlite3,test/test_sqlite*}
|
||||
use tk || rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{idlelib,lib-tk}
|
||||
fi
|
||||
|
||||
use threads || rm -fr "${libdir}/multiprocessing"
|
||||
use wininst || rm -f "${libdir})/distutils/command/"wininst-*.exe
|
||||
|
||||
dodoc Misc/{ACKS,HISTORY,NEWS} || die "dodoc failed"
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}/examples
|
||||
doins -r Tools || die "doins failed"
|
||||
fi
|
||||
|
||||
newconfd "${FILESDIR}/pydoc.conf" pydoc-${SLOT} || die "newconfd failed"
|
||||
newinitd "${FILESDIR}/pydoc.init" pydoc-${SLOT} || die "newinitd failed"
|
||||
sed \
|
||||
-e "s:@PYDOC_PORT_VARIABLE@:PYDOC${SLOT/./_}_PORT:" \
|
||||
-e "s:@PYDOC@:pydoc${SLOT}:" \
|
||||
-i "${ED}etc/conf.d/pydoc-${SLOT}" "${ED}etc/init.d/pydoc-${SLOT}" || die "sed failed"
|
||||
|
||||
# for python-exec
|
||||
python_export python${SLOT} EPYTHON PYTHON PYTHON_SITEDIR
|
||||
|
||||
# if not using a cross-compiler, use the fresh binary
|
||||
if ! tc-is-cross-compiler; then
|
||||
local PYTHON=./python \
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH+${LD_LIBRARY_PATH}:}.
|
||||
export LD_LIBRARY_PATH
|
||||
fi
|
||||
|
||||
echo "EPYTHON='${EPYTHON}'" > epython.py
|
||||
python_domodule epython.py
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
if has_version "<${CATEGORY}/${PN}-${SLOT}" && ! has_version "${CATEGORY}/${PN}:2.7"; then
|
||||
python_updater_warning="1"
|
||||
fi
|
||||
}
|
||||
|
||||
eselect_python_update() {
|
||||
[[ -z "${EROOT}" || (! -d "${EROOT}" && -d "${ROOT}") ]] && EROOT="${ROOT%/}${EPREFIX}/"
|
||||
|
||||
if [[ -z "$(eselect python show)" || ! -f "${EROOT}usr/bin/$(eselect python show)" ]]; then
|
||||
eselect python update
|
||||
fi
|
||||
|
||||
if [[ -z "$(eselect python show --python${PV%%.*})" || ! -f "${EROOT}usr/bin/$(eselect python show --python${PV%%.*})" ]]; then
|
||||
eselect python update --python${PV%%.*}
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
eselect_python_update
|
||||
|
||||
if [[ "${python_updater_warning}" == "1" ]]; then
|
||||
ewarn "You have just upgraded from an older version of Python."
|
||||
ewarn "You should switch active version of Python ${PV%%.*} and run"
|
||||
ewarn "'python-updater [options]' to rebuild Python modules."
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
eselect_python_update
|
||||
}
|
@ -0,0 +1,296 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-lang/python/python-3.1.5-r1.ebuild,v 1.3 2012/12/01 09:56:06 mgorny Exp $
|
||||
|
||||
EAPI="3"
|
||||
WANT_AUTOMAKE="none"
|
||||
WANT_LIBTOOL="none"
|
||||
|
||||
# Bootstrapping Python 3 requires any Python version.
|
||||
PYTHON_COMPAT=( python{2_5,2_6,2_7,3_1,3_2,3_3} )
|
||||
|
||||
inherit autotools eutils flag-o-matic multilib pax-utils python-any-r1 toolchain-funcs
|
||||
|
||||
MY_P="Python-${PV}"
|
||||
PATCHSET_REVISION="0"
|
||||
|
||||
DESCRIPTION="An interpreted, interactive, object-oriented programming language"
|
||||
HOMEPAGE="http://www.python.org/"
|
||||
SRC_URI="http://www.python.org/ftp/python/${PV}/${MY_P}.tar.xz
|
||||
mirror://gentoo/python-gentoo-patches-${PV}-${PATCHSET_REVISION}.tar.bz2"
|
||||
|
||||
LICENSE="PSF-2"
|
||||
SLOT="3.1"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd"
|
||||
IUSE="build doc elibc_uclibc examples gdbm ipv6 +ncurses +readline sqlite +ssl +threads tk +wide-unicode wininst +xml"
|
||||
|
||||
RDEPEND="app-arch/bzip2
|
||||
>=sys-libs/zlib-1.1.3
|
||||
virtual/libffi
|
||||
virtual/libintl
|
||||
!build? (
|
||||
gdbm? ( sys-libs/gdbm[berkdb] )
|
||||
ncurses? (
|
||||
>=sys-libs/ncurses-5.2
|
||||
readline? ( >=sys-libs/readline-4.1 )
|
||||
)
|
||||
sqlite? ( >=dev-db/sqlite-3.3.3:3 )
|
||||
ssl? ( dev-libs/openssl )
|
||||
tk? (
|
||||
>=dev-lang/tk-8.0
|
||||
dev-tcltk/blt
|
||||
)
|
||||
xml? ( >=dev-libs/expat-2.1 )
|
||||
)"
|
||||
DEPEND="${RDEPEND}
|
||||
${PYTHON_DEPS}
|
||||
virtual/pkgconfig
|
||||
>=sys-devel/autoconf-2.61
|
||||
!sys-devel/gcc[libffi]"
|
||||
RDEPEND+=" !build? ( app-misc/mime-types )
|
||||
doc? ( dev-python/python-docs:${SLOT} )"
|
||||
PDEPEND="app-admin/eselect-python
|
||||
app-admin/python-updater"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
src_prepare() {
|
||||
# Ensure that internal copies of expat, libffi and zlib are not used.
|
||||
rm -fr Modules/expat
|
||||
rm -fr Modules/_ctypes/libffi*
|
||||
rm -fr Modules/zlib
|
||||
|
||||
local excluded_patches
|
||||
if ! tc-is-cross-compiler; then
|
||||
excluded_patches="*_all_crosscompile.patch"
|
||||
fi
|
||||
|
||||
EPATCH_EXCLUDE="${excluded_patches}" EPATCH_SUFFIX="patch" \
|
||||
epatch "${WORKDIR}/${PV}-${PATCHSET_REVISION}"
|
||||
|
||||
sed -i -e "s:@@GENTOO_LIBDIR@@:$(get_libdir):g" \
|
||||
Lib/distutils/command/install.py \
|
||||
Lib/distutils/sysconfig.py \
|
||||
Lib/site.py \
|
||||
Makefile.pre.in \
|
||||
Modules/Setup.dist \
|
||||
Modules/getpath.c \
|
||||
setup.py || die "sed failed to replace @@GENTOO_LIBDIR@@"
|
||||
|
||||
eautoconf
|
||||
eautoheader
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
if use build; then
|
||||
# Disable extraneous modules with extra dependencies.
|
||||
export PYTHON_DISABLE_MODULES="gdbm _curses _curses_panel readline _sqlite3 _tkinter _elementtree pyexpat"
|
||||
export PYTHON_DISABLE_SSL="1"
|
||||
else
|
||||
local disable
|
||||
use gdbm || disable+=" gdbm"
|
||||
use ncurses || disable+=" _curses _curses_panel"
|
||||
use readline || disable+=" readline"
|
||||
use sqlite || disable+=" _sqlite3"
|
||||
use ssl || export PYTHON_DISABLE_SSL="1"
|
||||
use tk || disable+=" _tkinter"
|
||||
use xml || disable+=" _elementtree pyexpat" # _elementtree uses pyexpat.
|
||||
export PYTHON_DISABLE_MODULES="${disable}"
|
||||
|
||||
if ! use xml; then
|
||||
ewarn "You have configured Python without XML support."
|
||||
ewarn "This is NOT a recommended configuration as you"
|
||||
ewarn "may face problems parsing any XML documents."
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -n "${PYTHON_DISABLE_MODULES}" ]]; then
|
||||
einfo "Disabled modules: ${PYTHON_DISABLE_MODULES}"
|
||||
fi
|
||||
|
||||
if [[ "$(gcc-major-version)" -ge 4 ]]; then
|
||||
append-flags -fwrapv
|
||||
fi
|
||||
|
||||
filter-flags -malign-double
|
||||
|
||||
[[ "${ARCH}" == "alpha" ]] && append-flags -fPIC
|
||||
|
||||
# https://bugs.gentoo.org/show_bug.cgi?id=50309
|
||||
if is-flagq -O3; then
|
||||
is-flagq -fstack-protector-all && replace-flags -O3 -O2
|
||||
use hardened && replace-flags -O3 -O2
|
||||
fi
|
||||
|
||||
if tc-is-cross-compiler; then
|
||||
OPT="-O1" CFLAGS="" LDFLAGS="" CC="" \
|
||||
./configure --{build,host}=${CBUILD} || die "cross-configure failed"
|
||||
emake python Parser/pgen || die "cross-make failed"
|
||||
mv python hostpython
|
||||
mv Parser/pgen Parser/hostpgen
|
||||
make distclean
|
||||
sed -i \
|
||||
-e "/^HOSTPYTHON/s:=.*:=./hostpython:" \
|
||||
-e "/^HOSTPGEN/s:=.*:=./Parser/hostpgen:" \
|
||||
Makefile.pre.in || die "sed failed"
|
||||
fi
|
||||
|
||||
# Export CXX so it ends up in /usr/lib/python3.X/config/Makefile.
|
||||
tc-export CXX
|
||||
# The configure script fails to use pkg-config correctly.
|
||||
# http://bugs.python.org/issue15506
|
||||
export ac_cv_path_PKG_CONFIG=$(tc-getPKG_CONFIG)
|
||||
|
||||
# Set LDFLAGS so we link modules with -lpython3.1 correctly.
|
||||
# Needed on FreeBSD unless Python 3.1 is already installed.
|
||||
# Please query BSD team before removing this!
|
||||
append-ldflags "-L."
|
||||
|
||||
local dbmliborder
|
||||
if use gdbm; then
|
||||
dbmliborder+="${dbmliborder:+:}gdbm"
|
||||
fi
|
||||
|
||||
OPT="" econf \
|
||||
--with-fpectl \
|
||||
--enable-shared \
|
||||
$(use_enable ipv6) \
|
||||
$(use_with threads) \
|
||||
$(use_with wide-unicode) \
|
||||
--infodir='${prefix}/share/info' \
|
||||
--mandir='${prefix}/share/man' \
|
||||
--with-computed-gotos \
|
||||
--with-dbmliborder="${dbmliborder}" \
|
||||
--with-libc="" \
|
||||
--with-system-ffi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
default
|
||||
|
||||
# Work around bug 329499. See also bug 413751.
|
||||
pax-mark m python
|
||||
}
|
||||
|
||||
src_test() {
|
||||
# Tests will not work when cross compiling.
|
||||
if tc-is-cross-compiler; then
|
||||
elog "Disabling tests due to crosscompiling."
|
||||
return
|
||||
fi
|
||||
|
||||
if ! use threads; then
|
||||
ewarn "Disabling tests due to USE=\"-threads\""
|
||||
return
|
||||
fi
|
||||
|
||||
# Skip failing tests.
|
||||
local skipped_tests="distutils"
|
||||
|
||||
for test in ${skipped_tests}; do
|
||||
mv Lib/test/test_${test}.py "${T}"
|
||||
done
|
||||
|
||||
# Rerun failed tests in verbose mode (regrtest -w).
|
||||
emake test EXTRATESTOPTS="-w" < /dev/tty
|
||||
local result="$?"
|
||||
|
||||
for test in ${skipped_tests}; do
|
||||
mv "${T}/test_${test}.py" Lib/test
|
||||
done
|
||||
|
||||
elog "The following tests have been skipped:"
|
||||
for test in ${skipped_tests}; do
|
||||
elog "test_${test}.py"
|
||||
done
|
||||
|
||||
elog "If you would like to run them, you may:"
|
||||
elog "cd '${EPREFIX}/usr/$(get_libdir)/python${SLOT}/test'"
|
||||
elog "and run the tests separately."
|
||||
|
||||
if [[ "${result}" -ne 0 ]]; then
|
||||
die "emake test failed"
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
local libdir=${ED}/usr/$(get_libdir)/python${SLOT}
|
||||
|
||||
emake DESTDIR="${D}" altinstall || die "emake altinstall failed"
|
||||
|
||||
mv "${ED}usr/bin/python${SLOT}-config" "${ED}usr/bin/python-config-${SLOT}"
|
||||
|
||||
# Fix collisions between different slots of Python.
|
||||
mv "${ED}usr/bin/2to3" "${ED}usr/bin/2to3-${SLOT}"
|
||||
mv "${ED}usr/bin/pydoc3" "${ED}usr/bin/pydoc${SLOT}"
|
||||
mv "${ED}usr/bin/idle3" "${ED}usr/bin/idle${SLOT}"
|
||||
rm -f "${ED}usr/bin/smtpd.py"
|
||||
|
||||
if use build; then
|
||||
rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{idlelib,sqlite3,test,tkinter}
|
||||
else
|
||||
use elibc_uclibc && rm -fr "${libdir}/test"
|
||||
use sqlite || rm -fr "${libdir}/"{sqlite3,test/test_sqlite*}
|
||||
use tk || rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{idlelib,tkinter,test/test_tk*}
|
||||
fi
|
||||
|
||||
use threads || rm -fr "${libdir}/multiprocessing"
|
||||
use wininst || rm -f "${libdir}/distutils/command/"wininst-*.exe
|
||||
|
||||
dodoc Misc/{ACKS,HISTORY,NEWS} || die "dodoc failed"
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}/examples
|
||||
doins -r Tools || die "doins failed"
|
||||
fi
|
||||
|
||||
newconfd "${FILESDIR}/pydoc.conf" pydoc-${SLOT} || die "newconfd failed"
|
||||
newinitd "${FILESDIR}/pydoc.init" pydoc-${SLOT} || die "newinitd failed"
|
||||
sed \
|
||||
-e "s:@PYDOC_PORT_VARIABLE@:PYDOC${SLOT/./_}_PORT:" \
|
||||
-e "s:@PYDOC@:pydoc${SLOT}:" \
|
||||
-i "${ED}etc/conf.d/pydoc-${SLOT}" "${ED}etc/init.d/pydoc-${SLOT}" || die "sed failed"
|
||||
|
||||
# for python-exec
|
||||
python_export python${SLOT} EPYTHON PYTHON PYTHON_SITEDIR
|
||||
|
||||
# if not using a cross-compiler, use the fresh binary
|
||||
if ! tc-is-cross-compiler; then
|
||||
local PYTHON=./python \
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH+${LD_LIBRARY_PATH}:}.
|
||||
export LD_LIBRARY_PATH
|
||||
fi
|
||||
|
||||
echo "EPYTHON='${EPYTHON}'" > epython.py
|
||||
python_domodule epython.py
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
if has_version "<${CATEGORY}/${PN}-${SLOT}" && ! has_version ">=${CATEGORY}/${PN}-${SLOT}_alpha"; then
|
||||
python_updater_warning="1"
|
||||
fi
|
||||
}
|
||||
|
||||
eselect_python_update() {
|
||||
if [[ -z "$(eselect python show)" || ! -f "${EROOT}usr/bin/$(eselect python show)" ]]; then
|
||||
eselect python update
|
||||
fi
|
||||
|
||||
if [[ -z "$(eselect python show --python${PV%%.*})" || ! -f "${EROOT}usr/bin/$(eselect python show --python${PV%%.*})" ]]; then
|
||||
eselect python update --python${PV%%.*}
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
eselect_python_update
|
||||
|
||||
if [[ "${python_updater_warning}" == "1" ]]; then
|
||||
ewarn "You have just upgraded from an older version of Python."
|
||||
ewarn "You should switch active version of Python ${PV%%.*} and run"
|
||||
ewarn "'python-updater [options]' to rebuild Python modules."
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
eselect_python_update
|
||||
}
|
@ -0,0 +1,310 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-lang/python/python-3.2.3-r2.ebuild,v 1.3 2012/12/01 09:56:06 mgorny Exp $
|
||||
|
||||
EAPI="3"
|
||||
WANT_AUTOMAKE="none"
|
||||
WANT_LIBTOOL="none"
|
||||
|
||||
# Bootstrapping Python 3 requires any Python version.
|
||||
PYTHON_COMPAT=( python{2_5,2_6,2_7,3_1,3_2,3_3} )
|
||||
|
||||
inherit autotools eutils flag-o-matic multilib pax-utils python-any-r1 toolchain-funcs
|
||||
|
||||
MY_P="Python-${PV}"
|
||||
PATCHSET_REVISION="0"
|
||||
|
||||
DESCRIPTION="An interpreted, interactive, object-oriented programming language"
|
||||
HOMEPAGE="http://www.python.org/"
|
||||
SRC_URI="http://www.python.org/ftp/python/${PV}/${MY_P}.tar.xz
|
||||
mirror://gentoo/python-gentoo-patches-${PV}-${PATCHSET_REVISION}.tar.bz2"
|
||||
|
||||
LICENSE="PSF-2"
|
||||
SLOT="3.2"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
|
||||
IUSE="build doc elibc_uclibc examples gdbm ipv6 +ncurses +readline sqlite +ssl +threads tk +wide-unicode wininst +xml"
|
||||
|
||||
RDEPEND="app-arch/bzip2
|
||||
>=sys-libs/zlib-1.1.3
|
||||
virtual/libffi
|
||||
virtual/libintl
|
||||
!build? (
|
||||
gdbm? ( sys-libs/gdbm[berkdb] )
|
||||
ncurses? (
|
||||
>=sys-libs/ncurses-5.2
|
||||
readline? ( >=sys-libs/readline-4.1 )
|
||||
)
|
||||
sqlite? ( >=dev-db/sqlite-3.3.8:3[extensions] )
|
||||
ssl? ( dev-libs/openssl )
|
||||
tk? (
|
||||
>=dev-lang/tk-8.0
|
||||
dev-tcltk/blt
|
||||
)
|
||||
xml? ( >=dev-libs/expat-2.1 )
|
||||
)"
|
||||
DEPEND="${RDEPEND}
|
||||
${PYTHON_DEPS}
|
||||
virtual/pkgconfig
|
||||
>=sys-devel/autoconf-2.65
|
||||
!sys-devel/gcc[libffi]"
|
||||
RDEPEND+=" !build? ( app-misc/mime-types )
|
||||
doc? ( dev-python/python-docs:${SLOT} )"
|
||||
PDEPEND="app-admin/eselect-python
|
||||
app-admin/python-updater"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
pkg_setup() {
|
||||
if [[ "${PV}" =~ ^3\.2(\.[1234])?(_pre)? ]]; then
|
||||
rm -f "${EROOT}usr/$(get_libdir)/llibpython3.so"
|
||||
else
|
||||
die "Deprecated code not deleted"
|
||||
fi
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Ensure that internal copies of expat, libffi and zlib are not used.
|
||||
rm -fr Modules/expat
|
||||
rm -fr Modules/_ctypes/libffi*
|
||||
rm -fr Modules/zlib
|
||||
|
||||
local excluded_patches
|
||||
if ! tc-is-cross-compiler; then
|
||||
excluded_patches="*_all_crosscompile.patch"
|
||||
fi
|
||||
|
||||
EPATCH_EXCLUDE="${excluded_patches}" EPATCH_SUFFIX="patch" \
|
||||
epatch "${WORKDIR}/${PV}-${PATCHSET_REVISION}"
|
||||
epatch "${FILESDIR}"/${PN}-3.2.3-x32.patch
|
||||
|
||||
sed -i -e "s:@@GENTOO_LIBDIR@@:$(get_libdir):g" \
|
||||
Lib/distutils/command/install.py \
|
||||
Lib/distutils/sysconfig.py \
|
||||
Lib/site.py \
|
||||
Lib/sysconfig.py \
|
||||
Lib/test/test_site.py \
|
||||
Makefile.pre.in \
|
||||
Modules/Setup.dist \
|
||||
Modules/getpath.c \
|
||||
setup.py || die "sed failed to replace @@GENTOO_LIBDIR@@"
|
||||
|
||||
# Disable ABI flags.
|
||||
sed -e "s/ABIFLAGS=\"\${ABIFLAGS}.*\"/:/" -i configure.in || die "sed failed"
|
||||
|
||||
eautoconf
|
||||
eautoheader
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
if use build; then
|
||||
# Disable extraneous modules with extra dependencies.
|
||||
export PYTHON_DISABLE_MODULES="gdbm _curses _curses_panel readline _sqlite3 _tkinter _elementtree pyexpat"
|
||||
export PYTHON_DISABLE_SSL="1"
|
||||
else
|
||||
local disable
|
||||
use gdbm || disable+=" gdbm"
|
||||
use ncurses || disable+=" _curses _curses_panel"
|
||||
use readline || disable+=" readline"
|
||||
use sqlite || disable+=" _sqlite3"
|
||||
use ssl || export PYTHON_DISABLE_SSL="1"
|
||||
use tk || disable+=" _tkinter"
|
||||
use xml || disable+=" _elementtree pyexpat" # _elementtree uses pyexpat.
|
||||
export PYTHON_DISABLE_MODULES="${disable}"
|
||||
|
||||
if ! use xml; then
|
||||
ewarn "You have configured Python without XML support."
|
||||
ewarn "This is NOT a recommended configuration as you"
|
||||
ewarn "may face problems parsing any XML documents."
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -n "${PYTHON_DISABLE_MODULES}" ]]; then
|
||||
einfo "Disabled modules: ${PYTHON_DISABLE_MODULES}"
|
||||
fi
|
||||
|
||||
if [[ "$(gcc-major-version)" -ge 4 ]]; then
|
||||
append-flags -fwrapv
|
||||
fi
|
||||
|
||||
filter-flags -malign-double
|
||||
|
||||
[[ "${ARCH}" == "alpha" ]] && append-flags -fPIC
|
||||
|
||||
# https://bugs.gentoo.org/show_bug.cgi?id=50309
|
||||
if is-flagq -O3; then
|
||||
is-flagq -fstack-protector-all && replace-flags -O3 -O2
|
||||
use hardened && replace-flags -O3 -O2
|
||||
fi
|
||||
|
||||
if tc-is-cross-compiler; then
|
||||
OPT="-O1" CFLAGS="" LDFLAGS="" CC="" \
|
||||
./configure --{build,host}=${CBUILD} || die "cross-configure failed"
|
||||
emake python Parser/pgen || die "cross-make failed"
|
||||
mv python hostpython
|
||||
mv Parser/pgen Parser/hostpgen
|
||||
make distclean
|
||||
sed -i \
|
||||
-e "/^HOSTPYTHON/s:=.*:=./hostpython:" \
|
||||
-e "/^HOSTPGEN/s:=.*:=./Parser/hostpgen:" \
|
||||
Makefile.pre.in || die "sed failed"
|
||||
fi
|
||||
|
||||
# Export CXX so it ends up in /usr/lib/python3.X/config/Makefile.
|
||||
tc-export CXX
|
||||
# The configure script fails to use pkg-config correctly.
|
||||
# http://bugs.python.org/issue15506
|
||||
export ac_cv_path_PKG_CONFIG=$(tc-getPKG_CONFIG)
|
||||
|
||||
# Set LDFLAGS so we link modules with -lpython3.2 correctly.
|
||||
# Needed on FreeBSD unless Python 3.2 is already installed.
|
||||
# Please query BSD team before removing this!
|
||||
append-ldflags "-L."
|
||||
|
||||
local dbmliborder
|
||||
if use gdbm; then
|
||||
dbmliborder+="${dbmliborder:+:}gdbm"
|
||||
fi
|
||||
|
||||
OPT="" econf \
|
||||
--with-fpectl \
|
||||
--enable-shared \
|
||||
$(use_enable ipv6) \
|
||||
$(use_with threads) \
|
||||
$(use_with wide-unicode) \
|
||||
--infodir='${prefix}/share/info' \
|
||||
--mandir='${prefix}/share/man' \
|
||||
--with-computed-gotos \
|
||||
--with-dbmliborder="${dbmliborder}" \
|
||||
--with-libc="" \
|
||||
--enable-loadable-sqlite-extensions \
|
||||
--with-system-expat \
|
||||
--with-system-ffi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake CPPFLAGS="" CFLAGS="" LDFLAGS="" || die "emake failed"
|
||||
|
||||
# Work around bug 329499. See also bug 413751.
|
||||
pax-mark m python
|
||||
}
|
||||
|
||||
src_test() {
|
||||
# Tests will not work when cross compiling.
|
||||
if tc-is-cross-compiler; then
|
||||
elog "Disabling tests due to crosscompiling."
|
||||
return
|
||||
fi
|
||||
|
||||
# Skip failing tests.
|
||||
local skipped_tests="gdb"
|
||||
|
||||
for test in ${skipped_tests}; do
|
||||
mv Lib/test/test_${test}.py "${T}"
|
||||
done
|
||||
|
||||
# Rerun failed tests in verbose mode (regrtest -w).
|
||||
emake test EXTRATESTOPTS="-w" CPPFLAGS="" CFLAGS="" LDFLAGS="" < /dev/tty
|
||||
local result="$?"
|
||||
|
||||
for test in ${skipped_tests}; do
|
||||
mv "${T}/test_${test}.py" Lib/test
|
||||
done
|
||||
|
||||
elog "The following tests have been skipped:"
|
||||
for test in ${skipped_tests}; do
|
||||
elog "test_${test}.py"
|
||||
done
|
||||
|
||||
elog "If you would like to run them, you may:"
|
||||
elog "cd '${EPREFIX}/usr/$(get_libdir)/python${SLOT}/test'"
|
||||
elog "and run the tests separately."
|
||||
|
||||
if [[ "${result}" -ne 0 ]]; then
|
||||
die "emake test failed"
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
local libdir=${ED}/usr/$(get_libdir)/python${SLOT}
|
||||
|
||||
emake DESTDIR="${D}" altinstall || die "emake altinstall failed"
|
||||
|
||||
sed \
|
||||
-e "s/\(CONFIGURE_LDFLAGS=\).*/\1/" \
|
||||
-e "s/\(PY_LDFLAGS=\).*/\1/" \
|
||||
-i "${libdir}/config-${SLOT}/Makefile" || die "sed failed"
|
||||
|
||||
mv "${ED}usr/bin/python${SLOT}-config" "${ED}usr/bin/python-config-${SLOT}"
|
||||
|
||||
# Fix collisions between different slots of Python.
|
||||
rm -f "${ED}usr/$(get_libdir)/libpython3.so"
|
||||
|
||||
if use build; then
|
||||
rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{idlelib,sqlite3,test,tkinter}
|
||||
else
|
||||
use elibc_uclibc && rm -fr "${libdir}/test"
|
||||
use sqlite || rm -fr "${libdir}/"{sqlite3,test/test_sqlite*}
|
||||
use tk || rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{idlelib,tkinter,test/test_tk*}
|
||||
fi
|
||||
|
||||
use threads || rm -fr "${libdir}/multiprocessing"
|
||||
use wininst || rm -f "${libdir}/distutils/command/"wininst-*.exe
|
||||
|
||||
dodoc Misc/{ACKS,HISTORY,NEWS} || die "dodoc failed"
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}/examples
|
||||
find Tools -name __pycache__ -print0 | xargs -0 rm -fr
|
||||
doins -r Tools || die "doins failed"
|
||||
fi
|
||||
|
||||
newconfd "${FILESDIR}/pydoc.conf" pydoc-${SLOT} || die "newconfd failed"
|
||||
newinitd "${FILESDIR}/pydoc.init" pydoc-${SLOT} || die "newinitd failed"
|
||||
sed \
|
||||
-e "s:@PYDOC_PORT_VARIABLE@:PYDOC${SLOT/./_}_PORT:" \
|
||||
-e "s:@PYDOC@:pydoc${SLOT}:" \
|
||||
-i "${ED}etc/conf.d/pydoc-${SLOT}" "${ED}etc/init.d/pydoc-${SLOT}" || die "sed failed"
|
||||
|
||||
# for python-exec
|
||||
python_export python${SLOT} EPYTHON PYTHON PYTHON_SITEDIR
|
||||
|
||||
# if not using a cross-compiler, use the fresh binary
|
||||
if ! tc-is-cross-compiler; then
|
||||
local PYTHON=./python \
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH+${LD_LIBRARY_PATH}:}.
|
||||
export LD_LIBRARY_PATH
|
||||
fi
|
||||
|
||||
echo "EPYTHON='${EPYTHON}'" > epython.py
|
||||
python_domodule epython.py
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
if has_version "<${CATEGORY}/${PN}-${SLOT}" && ! has_version ">=${CATEGORY}/${PN}-${SLOT}_alpha"; then
|
||||
python_updater_warning="1"
|
||||
fi
|
||||
}
|
||||
|
||||
eselect_python_update() {
|
||||
if [[ -z "$(eselect python show)" || ! -f "${EROOT}usr/bin/$(eselect python show)" ]]; then
|
||||
eselect python update
|
||||
fi
|
||||
|
||||
if [[ -z "$(eselect python show --python${PV%%.*})" || ! -f "${EROOT}usr/bin/$(eselect python show --python${PV%%.*})" ]]; then
|
||||
eselect python update --python${PV%%.*}
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
eselect_python_update
|
||||
|
||||
if [[ "${python_updater_warning}" == "1" ]]; then
|
||||
ewarn "You have just upgraded from an older version of Python."
|
||||
ewarn "You should switch active version of Python ${PV%%.*} and run"
|
||||
ewarn "'python-updater [options]' to rebuild Python modules."
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
eselect_python_update
|
||||
}
|
@ -0,0 +1,300 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-lang/python/python-3.3.0-r1.ebuild,v 1.3 2012/12/01 09:56:06 mgorny Exp $
|
||||
|
||||
EAPI="3"
|
||||
WANT_AUTOMAKE="none"
|
||||
WANT_LIBTOOL="none"
|
||||
|
||||
# Bootstrapping Python 3 requires any Python version.
|
||||
PYTHON_COMPAT=( python{2_5,2_6,2_7,3_1,3_2,3_3} )
|
||||
|
||||
inherit autotools eutils flag-o-matic multilib pax-utils python-any-r1 toolchain-funcs
|
||||
|
||||
MY_P="Python-${PV}"
|
||||
PATCHSET_REVISION="1"
|
||||
|
||||
DESCRIPTION="An interpreted, interactive, object-oriented programming language"
|
||||
HOMEPAGE="http://www.python.org/"
|
||||
SRC_URI="http://www.python.org/ftp/python/${PV}/${MY_P}.tar.xz
|
||||
mirror://gentoo/python-gentoo-patches-${PV}-${PATCHSET_REVISION}.tar.bz2"
|
||||
|
||||
LICENSE="PSF-2"
|
||||
SLOT="3.3"
|
||||
KEYWORDS=""
|
||||
IUSE="build doc elibc_uclibc examples gdbm ipv6 +ncurses +readline sqlite +ssl +threads tk wininst +xml"
|
||||
|
||||
RDEPEND="app-arch/bzip2
|
||||
>=sys-libs/zlib-1.1.3
|
||||
virtual/libffi
|
||||
virtual/libintl
|
||||
!build? (
|
||||
gdbm? ( sys-libs/gdbm[berkdb] )
|
||||
ncurses? (
|
||||
>=sys-libs/ncurses-5.2
|
||||
readline? ( >=sys-libs/readline-4.1 )
|
||||
)
|
||||
sqlite? ( >=dev-db/sqlite-3.3.8:3[extensions] )
|
||||
ssl? ( dev-libs/openssl )
|
||||
tk? (
|
||||
>=dev-lang/tk-8.0
|
||||
dev-tcltk/blt
|
||||
)
|
||||
xml? ( >=dev-libs/expat-2.1 )
|
||||
)"
|
||||
DEPEND="${RDEPEND}
|
||||
${PYTHON_DEPS}
|
||||
virtual/pkgconfig
|
||||
>=sys-devel/autoconf-2.65
|
||||
!sys-devel/gcc[libffi]"
|
||||
RDEPEND+=" !build? ( app-misc/mime-types )
|
||||
doc? ( dev-python/python-docs:${SLOT} )"
|
||||
PDEPEND="app-admin/eselect-python
|
||||
app-admin/python-updater"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
src_prepare() {
|
||||
# Ensure that internal copies of expat, libffi and zlib are not used.
|
||||
rm -fr Modules/expat
|
||||
rm -fr Modules/_ctypes/libffi*
|
||||
rm -fr Modules/zlib
|
||||
|
||||
local excluded_patches
|
||||
if ! tc-is-cross-compiler; then
|
||||
excluded_patches="*_all_crosscompile.patch"
|
||||
fi
|
||||
|
||||
EPATCH_EXCLUDE="${excluded_patches}" EPATCH_SUFFIX="patch" \
|
||||
epatch "${WORKDIR}/${PV}-${PATCHSET_REVISION}"
|
||||
|
||||
sed -i -e "s:@@GENTOO_LIBDIR@@:$(get_libdir):g" \
|
||||
Lib/distutils/command/install.py \
|
||||
Lib/distutils/sysconfig.py \
|
||||
Lib/site.py \
|
||||
Lib/sysconfig.py \
|
||||
Lib/test/test_site.py \
|
||||
Makefile.pre.in \
|
||||
Modules/Setup.dist \
|
||||
Modules/getpath.c \
|
||||
setup.py || die "sed failed to replace @@GENTOO_LIBDIR@@"
|
||||
|
||||
# Disable ABI flags.
|
||||
sed -e "s/ABIFLAGS=\"\${ABIFLAGS}.*\"/:/" -i configure.ac || die "sed failed"
|
||||
|
||||
eautoconf
|
||||
eautoheader
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
if use build; then
|
||||
# Disable extraneous modules with extra dependencies.
|
||||
export PYTHON_DISABLE_MODULES="gdbm _curses _curses_panel readline _sqlite3 _tkinter _elementtree pyexpat"
|
||||
export PYTHON_DISABLE_SSL="1"
|
||||
else
|
||||
local disable
|
||||
use gdbm || disable+=" gdbm"
|
||||
use ncurses || disable+=" _curses _curses_panel"
|
||||
use readline || disable+=" readline"
|
||||
use sqlite || disable+=" _sqlite3"
|
||||
use ssl || export PYTHON_DISABLE_SSL="1"
|
||||
use tk || disable+=" _tkinter"
|
||||
use xml || disable+=" _elementtree pyexpat" # _elementtree uses pyexpat.
|
||||
export PYTHON_DISABLE_MODULES="${disable}"
|
||||
|
||||
if ! use xml; then
|
||||
ewarn "You have configured Python without XML support."
|
||||
ewarn "This is NOT a recommended configuration as you"
|
||||
ewarn "may face problems parsing any XML documents."
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -n "${PYTHON_DISABLE_MODULES}" ]]; then
|
||||
einfo "Disabled modules: ${PYTHON_DISABLE_MODULES}"
|
||||
fi
|
||||
|
||||
if [[ "$(gcc-major-version)" -ge 4 ]]; then
|
||||
append-flags -fwrapv
|
||||
fi
|
||||
|
||||
filter-flags -malign-double
|
||||
|
||||
[[ "${ARCH}" == "alpha" ]] && append-flags -fPIC
|
||||
|
||||
# https://bugs.gentoo.org/show_bug.cgi?id=50309
|
||||
if is-flagq -O3; then
|
||||
is-flagq -fstack-protector-all && replace-flags -O3 -O2
|
||||
use hardened && replace-flags -O3 -O2
|
||||
fi
|
||||
|
||||
if tc-is-cross-compiler; then
|
||||
OPT="-O1" CFLAGS="" LDFLAGS="" CC="" \
|
||||
./configure --{build,host}=${CBUILD} || die "cross-configure failed"
|
||||
emake python Parser/pgen || die "cross-make failed"
|
||||
mv python hostpython
|
||||
mv Parser/pgen Parser/hostpgen
|
||||
make distclean
|
||||
sed -i \
|
||||
-e "/^HOSTPYTHON/s:=.*:=./hostpython:" \
|
||||
-e "/^HOSTPGEN/s:=.*:=./Parser/hostpgen:" \
|
||||
Makefile.pre.in || die "sed failed"
|
||||
fi
|
||||
|
||||
# Export CXX so it ends up in /usr/lib/python3.X/config/Makefile.
|
||||
tc-export CXX
|
||||
# The configure script fails to use pkg-config correctly.
|
||||
# http://bugs.python.org/issue15506
|
||||
export ac_cv_path_PKG_CONFIG=$(tc-getPKG_CONFIG)
|
||||
|
||||
# Set LDFLAGS so we link modules with -lpython3.2 correctly.
|
||||
# Needed on FreeBSD unless Python 3.2 is already installed.
|
||||
# Please query BSD team before removing this!
|
||||
append-ldflags "-L."
|
||||
|
||||
local dbmliborder
|
||||
if use gdbm; then
|
||||
dbmliborder+="${dbmliborder:+:}gdbm"
|
||||
fi
|
||||
|
||||
OPT="" econf \
|
||||
--with-fpectl \
|
||||
--enable-shared \
|
||||
$(use_enable ipv6) \
|
||||
$(use_with threads) \
|
||||
--infodir='${prefix}/share/info' \
|
||||
--mandir='${prefix}/share/man' \
|
||||
--with-computed-gotos \
|
||||
--with-dbmliborder="${dbmliborder}" \
|
||||
--with-libc="" \
|
||||
--enable-loadable-sqlite-extensions \
|
||||
--with-system-expat \
|
||||
--with-system-ffi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake CPPFLAGS="" CFLAGS="" LDFLAGS="" || die "emake failed"
|
||||
|
||||
# Work around bug 329499. See also bug 413751.
|
||||
pax-mark m python
|
||||
}
|
||||
|
||||
src_test() {
|
||||
# Tests will not work when cross compiling.
|
||||
if tc-is-cross-compiler; then
|
||||
elog "Disabling tests due to crosscompiling."
|
||||
return
|
||||
fi
|
||||
|
||||
# Skip failing tests.
|
||||
local skipped_tests="gdb"
|
||||
|
||||
for test in ${skipped_tests}; do
|
||||
mv Lib/test/test_${test}.py "${T}"
|
||||
done
|
||||
|
||||
# Rerun failed tests in verbose mode (regrtest -w).
|
||||
emake test EXTRATESTOPTS="-w" CPPFLAGS="" CFLAGS="" LDFLAGS="" < /dev/tty
|
||||
local result="$?"
|
||||
|
||||
for test in ${skipped_tests}; do
|
||||
mv "${T}/test_${test}.py" Lib/test
|
||||
done
|
||||
|
||||
elog "The following tests have been skipped:"
|
||||
for test in ${skipped_tests}; do
|
||||
elog "test_${test}.py"
|
||||
done
|
||||
|
||||
elog "If you would like to run them, you may:"
|
||||
elog "cd '${EPREFIX}/usr/$(get_libdir)/python${SLOT}/test'"
|
||||
elog "and run the tests separately."
|
||||
|
||||
if [[ "${result}" -ne 0 ]]; then
|
||||
die "emake test failed"
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
local libdir=${ED}/usr/$(get_libdir)/python${SLOT}
|
||||
|
||||
emake DESTDIR="${D}" altinstall || die "emake altinstall failed"
|
||||
|
||||
sed \
|
||||
-e "s/\(CONFIGURE_LDFLAGS=\).*/\1/" \
|
||||
-e "s/\(PY_LDFLAGS=\).*/\1/" \
|
||||
-i "${libdir}/config-${SLOT}/Makefile" || die "sed failed"
|
||||
|
||||
mv "${ED}usr/bin/python${SLOT}-config" "${ED}usr/bin/python-config-${SLOT}"
|
||||
|
||||
# Fix collisions between different slots of Python.
|
||||
rm -f "${ED}usr/$(get_libdir)/libpython3.so"
|
||||
|
||||
if use build; then
|
||||
rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{idlelib,sqlite3,test,tkinter}
|
||||
else
|
||||
use elibc_uclibc && rm -fr "${libdir}/test"
|
||||
use sqlite || rm -fr "${libdir}/"{sqlite3,test/test_sqlite*}
|
||||
use tk || rm -fr "${ED}usr/bin/idle${SLOT}" "${libdir}/"{idlelib,tkinter,test/test_tk*}
|
||||
fi
|
||||
|
||||
use threads || rm -fr "${libdir}/multiprocessing"
|
||||
use wininst || rm -f "${libdir}/distutils/command/"wininst-*.exe
|
||||
|
||||
dodoc Misc/{ACKS,HISTORY,NEWS} || die "dodoc failed"
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}/examples
|
||||
find Tools -name __pycache__ -print0 | xargs -0 rm -fr
|
||||
doins -r Tools || die "doins failed"
|
||||
fi
|
||||
|
||||
newconfd "${FILESDIR}/pydoc.conf" pydoc-${SLOT} || die "newconfd failed"
|
||||
newinitd "${FILESDIR}/pydoc.init" pydoc-${SLOT} || die "newinitd failed"
|
||||
sed \
|
||||
-e "s:@PYDOC_PORT_VARIABLE@:PYDOC${SLOT/./_}_PORT:" \
|
||||
-e "s:@PYDOC@:pydoc${SLOT}:" \
|
||||
-i "${ED}etc/conf.d/pydoc-${SLOT}" "${ED}etc/init.d/pydoc-${SLOT}" || die "sed failed"
|
||||
|
||||
# for python-exec
|
||||
python_export python${SLOT} EPYTHON PYTHON PYTHON_SITEDIR
|
||||
|
||||
# if not using a cross-compiler, use the fresh binary
|
||||
if ! tc-is-cross-compiler; then
|
||||
local PYTHON=./python \
|
||||
LD_LIBRARY_PATH=${LD_LIBRARY_PATH+${LD_LIBRARY_PATH}:}.
|
||||
export LD_LIBRARY_PATH
|
||||
fi
|
||||
|
||||
echo "EPYTHON='${EPYTHON}'" > epython.py
|
||||
python_domodule epython.py
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
if has_version "<${CATEGORY}/${PN}-${SLOT}" && ! has_version ">=${CATEGORY}/${PN}-${SLOT}_alpha"; then
|
||||
python_updater_warning="1"
|
||||
fi
|
||||
}
|
||||
|
||||
eselect_python_update() {
|
||||
if [[ -z "$(eselect python show)" || ! -f "${EROOT}usr/bin/$(eselect python show)" ]]; then
|
||||
eselect python update
|
||||
fi
|
||||
|
||||
if [[ -z "$(eselect python show --python${PV%%.*})" || ! -f "${EROOT}usr/bin/$(eselect python show --python${PV%%.*})" ]]; then
|
||||
eselect python update --python${PV%%.*}
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
eselect_python_update
|
||||
|
||||
if [[ "${python_updater_warning}" == "1" ]]; then
|
||||
ewarn "You have just upgraded from an older version of Python."
|
||||
ewarn "You should switch active version of Python ${PV%%.*} and run"
|
||||
ewarn "'python-updater [options]' to rebuild Python modules."
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
eselect_python_update
|
||||
}
|
@ -0,0 +1,22 @@
|
||||
--- example/Makefile.am
|
||||
+++ example/Makefile.am
|
||||
@@ -37,8 +37,7 @@
|
||||
otfdump_LDADD = ${CommonLDADD}
|
||||
|
||||
otfview_SOURCE = otfview.c
|
||||
-otfview_LDADD = ${CommonLDADD}
|
||||
-otfview_LDFLAGS = ${X_LIBS} ${X_PRE_LIBS} @X11_XT_XAW_XMU@ ${X_EXTRA_LIBS}
|
||||
+otfview_LDADD = ${CommonLDADD} ${X_LIBS} ${X_PRE_LIBS} @X11_XT_XAW_XMU@ ${X_EXTRA_LIBS}
|
||||
|
||||
otftobdf_SOURCE = otftobdf.c
|
||||
otftobdf_LDADD = ${CommonLDADD}
|
||||
--- libotf.pc.in
|
||||
+++ libotf.pc.in
|
||||
@@ -7,5 +7,6 @@
|
||||
Description: OpenType font library
|
||||
Version: @PACKAGE_VERSION@
|
||||
Requires: freetype2
|
||||
-Libs: @FREETYPE_LD_FLAGS@ -L${libdir} -lotf
|
||||
+Libs: -L${libdir} -lotf
|
||||
+Libs.private: @FREETYPE_LD_FLAGS@
|
||||
Cflags: @FREETYPE_INC@ -I${includedir}
|
@ -1,39 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-libs/libotf/libotf-0.9.12.ebuild,v 1.2 2012/05/04 18:35:44 jdhore Exp $
|
||||
|
||||
inherit autotools
|
||||
|
||||
DESCRIPTION="Library for handling OpenType fonts (OTF)"
|
||||
HOMEPAGE="http://www.m17n.org/libotf/"
|
||||
SRC_URI="http://www.m17n.org/libotf/${P}.tar.gz"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86"
|
||||
IUSE="X"
|
||||
|
||||
RDEPEND=">=media-libs/freetype-2.1
|
||||
X? (
|
||||
x11-libs/libXaw
|
||||
x11-libs/libICE
|
||||
)"
|
||||
|
||||
DEPEND="${RDEPEND}
|
||||
>=sys-apps/sed-4
|
||||
virtual/pkgconfig"
|
||||
|
||||
src_unpack() {
|
||||
unpack ${A}
|
||||
cd "${S}"
|
||||
if ! use X ; then
|
||||
sed -i -e '/^bin_PROGRAMS/s/otfview//' example/Makefile.am || die
|
||||
eautoreconf
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install || die
|
||||
|
||||
dodoc AUTHORS NEWS README ChangeLog
|
||||
}
|
@ -0,0 +1,45 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-libs/libotf/libotf-0.9.13.ebuild,v 1.2 2012/11/30 08:31:04 jlec Exp $
|
||||
|
||||
EAPI=5
|
||||
inherit autotools eutils
|
||||
|
||||
DESCRIPTION="Library for handling OpenType fonts (OTF)"
|
||||
HOMEPAGE="http://www.nongnu.org/m17n/"
|
||||
SRC_URI="mirror://nongnu/m17n/${P}.tar.gz"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux"
|
||||
IUSE="static-libs X"
|
||||
|
||||
RDEPEND=">=media-libs/freetype-2.4.9
|
||||
X? (
|
||||
x11-libs/libX11
|
||||
x11-libs/libXaw
|
||||
x11-libs/libXt
|
||||
)"
|
||||
DEPEND="${RDEPEND}
|
||||
X? (
|
||||
x11-libs/libICE
|
||||
x11-libs/libXmu
|
||||
x11-proto/xproto
|
||||
)"
|
||||
|
||||
DOCS="AUTHORS ChangeLog NEWS README"
|
||||
|
||||
src_prepare() {
|
||||
epatch "${FILESDIR}"/${P}-build.patch
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
export ac_cv_header_X11_Xaw_Command_h=$(usex X)
|
||||
econf $(use_enable static-libs static)
|
||||
}
|
||||
|
||||
src_install() {
|
||||
default
|
||||
prune_libtool_files
|
||||
}
|
@ -1,39 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-libs/libotf/libotf-0.9.9.ebuild,v 1.3 2012/11/14 14:13:40 jlec Exp $
|
||||
|
||||
inherit autotools
|
||||
|
||||
DESCRIPTION="Library for handling OpenType fonts (OTF)"
|
||||
HOMEPAGE="http://www.m17n.org/libotf/"
|
||||
SRC_URI="http://www.m17n.org/libotf/${P}.tar.gz"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux"
|
||||
IUSE="X"
|
||||
|
||||
RDEPEND=">=media-libs/freetype-2.1
|
||||
X? (
|
||||
x11-libs/libXaw
|
||||
x11-libs/libICE
|
||||
)"
|
||||
|
||||
DEPEND="${RDEPEND}
|
||||
>=sys-apps/sed-4
|
||||
virtual/pkgconfig"
|
||||
|
||||
src_unpack() {
|
||||
unpack ${A}
|
||||
cd "${S}"
|
||||
if ! use X ; then
|
||||
sed -i -e '/^bin_PROGRAMS/s/otfview//' example/Makefile.am || die
|
||||
eautoreconf
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install || die
|
||||
|
||||
dodoc AUTHORS NEWS README ChangeLog
|
||||
}
|
@ -1,54 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-python/apsw/apsw-3.7.10.1.ebuild,v 1.2 2012/02/20 15:10:58 patrick Exp $
|
||||
|
||||
EAPI="4"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
RESTRICT_PYTHON_ABIS="*-jython 2.7-pypy-*"
|
||||
|
||||
inherit distutils eutils versionator
|
||||
|
||||
MY_PV="$(replace_version_separator 3 -r)"
|
||||
|
||||
DESCRIPTION="APSW - Another Python SQLite Wrapper"
|
||||
HOMEPAGE="http://code.google.com/p/apsw/"
|
||||
SRC_URI="http://apsw.googlecode.com/files/${PN}-${MY_PV}.zip"
|
||||
|
||||
LICENSE="as-is"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ppc64 ~x86"
|
||||
IUSE="doc"
|
||||
|
||||
RDEPEND=">=dev-db/sqlite-$(get_version_component_range 1-3)[extensions]"
|
||||
DEPEND="${RDEPEND}
|
||||
app-arch/unzip"
|
||||
|
||||
S="${WORKDIR}/${PN}-${MY_PV}"
|
||||
|
||||
PYTHON_CFLAGS=("2.* + -fno-strict-aliasing")
|
||||
|
||||
src_prepare() {
|
||||
distutils_src_prepare
|
||||
epatch "${FILESDIR}/${PN}-3.6.20.1-fix_tests.patch"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
distutils_src_compile --enable=load_extension
|
||||
}
|
||||
|
||||
src_test() {
|
||||
echo "$(PYTHON -f)" setup.py build_test_extension
|
||||
"$(PYTHON -f)" setup.py build_test_extension || die "Building of test loadable extension failed"
|
||||
|
||||
testing() {
|
||||
PYTHONPATH="$(ls -d build-${PYTHON_ABI}/lib.*)" "$(PYTHON)" tests.py -v
|
||||
}
|
||||
python_execute_function testing
|
||||
}
|
||||
|
||||
src_install() {
|
||||
distutils_src_install
|
||||
if use doc ; then
|
||||
dohtml -r doc/*
|
||||
fi
|
||||
}
|
@ -1,54 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-python/apsw/apsw-3.7.11.1.ebuild,v 1.1 2012/04/03 07:13:01 radhermit Exp $
|
||||
|
||||
EAPI="4"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
RESTRICT_PYTHON_ABIS="*-jython 2.7-pypy-*"
|
||||
|
||||
inherit distutils eutils versionator
|
||||
|
||||
MY_PV="$(replace_version_separator 3 -r)"
|
||||
|
||||
DESCRIPTION="APSW - Another Python SQLite Wrapper"
|
||||
HOMEPAGE="http://code.google.com/p/apsw/"
|
||||
SRC_URI="http://apsw.googlecode.com/files/${PN}-${MY_PV}.zip"
|
||||
|
||||
LICENSE="as-is"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ppc64 ~x86"
|
||||
IUSE="doc"
|
||||
|
||||
RDEPEND=">=dev-db/sqlite-$(get_version_component_range 1-3)[extensions]"
|
||||
DEPEND="${RDEPEND}
|
||||
app-arch/unzip"
|
||||
|
||||
S="${WORKDIR}/${PN}-${MY_PV}"
|
||||
|
||||
PYTHON_CFLAGS=("2.* + -fno-strict-aliasing")
|
||||
|
||||
src_prepare() {
|
||||
distutils_src_prepare
|
||||
epatch "${FILESDIR}/${PN}-3.6.20.1-fix_tests.patch"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
distutils_src_compile --enable=load_extension
|
||||
}
|
||||
|
||||
src_test() {
|
||||
echo "$(PYTHON -f)" setup.py build_test_extension
|
||||
"$(PYTHON -f)" setup.py build_test_extension || die "Building of test loadable extension failed"
|
||||
|
||||
testing() {
|
||||
PYTHONPATH="$(ls -d build-${PYTHON_ABI}/lib.*)" "$(PYTHON)" tests.py -v
|
||||
}
|
||||
python_execute_function testing
|
||||
}
|
||||
|
||||
src_install() {
|
||||
distutils_src_install
|
||||
if use doc ; then
|
||||
dohtml -r doc/*
|
||||
fi
|
||||
}
|
@ -1,54 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-python/apsw/apsw-3.7.12.1.ebuild,v 1.1 2012/05/31 14:18:09 radhermit Exp $
|
||||
|
||||
EAPI="4"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
RESTRICT_PYTHON_ABIS="*-jython 2.7-pypy-*"
|
||||
|
||||
inherit distutils eutils versionator
|
||||
|
||||
MY_PV="$(replace_version_separator 3 -r)"
|
||||
|
||||
DESCRIPTION="APSW - Another Python SQLite Wrapper"
|
||||
HOMEPAGE="http://code.google.com/p/apsw/"
|
||||
SRC_URI="http://apsw.googlecode.com/files/${PN}-${MY_PV}.zip"
|
||||
|
||||
LICENSE="as-is"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ppc64 ~x86"
|
||||
IUSE="doc"
|
||||
|
||||
RDEPEND=">=dev-db/sqlite-$(get_version_component_range 1-3)[extensions]"
|
||||
DEPEND="${RDEPEND}
|
||||
app-arch/unzip"
|
||||
|
||||
S="${WORKDIR}/${PN}-${MY_PV}"
|
||||
|
||||
PYTHON_CFLAGS=("2.* + -fno-strict-aliasing")
|
||||
|
||||
src_prepare() {
|
||||
distutils_src_prepare
|
||||
epatch "${FILESDIR}/${PN}-3.6.20.1-fix_tests.patch"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
distutils_src_compile --enable=load_extension
|
||||
}
|
||||
|
||||
src_test() {
|
||||
echo "$(PYTHON -f)" setup.py build_test_extension
|
||||
"$(PYTHON -f)" setup.py build_test_extension || die "Building of test loadable extension failed"
|
||||
|
||||
testing() {
|
||||
PYTHONPATH="$(ls -d build-${PYTHON_ABI}/lib.*)" "$(PYTHON)" tests.py -v
|
||||
}
|
||||
python_execute_function testing
|
||||
}
|
||||
|
||||
src_install() {
|
||||
distutils_src_install
|
||||
if use doc ; then
|
||||
dohtml -r doc/*
|
||||
fi
|
||||
}
|
@ -1,53 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-python/apsw/apsw-3.7.6.2.1.ebuild,v 1.3 2012/02/20 15:10:58 patrick Exp $
|
||||
|
||||
EAPI="3"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
RESTRICT_PYTHON_ABIS="*-jython 2.7-pypy-*"
|
||||
|
||||
inherit distutils eutils versionator
|
||||
|
||||
MY_PV="$(replace_version_separator 4 -r)"
|
||||
|
||||
DESCRIPTION="APSW - Another Python SQLite Wrapper"
|
||||
HOMEPAGE="http://code.google.com/p/apsw/"
|
||||
SRC_URI="http://apsw.googlecode.com/files/${PN}-${MY_PV}.zip"
|
||||
|
||||
LICENSE="as-is"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ppc64 x86"
|
||||
IUSE=""
|
||||
|
||||
RDEPEND=">=dev-db/sqlite-$(get_version_component_range 1-3)[extensions]"
|
||||
DEPEND="${RDEPEND}
|
||||
app-arch/unzip"
|
||||
|
||||
S="${WORKDIR}/${PN}-${MY_PV}"
|
||||
|
||||
PYTHON_CFLAGS=("2.* + -fno-strict-aliasing")
|
||||
|
||||
src_prepare() {
|
||||
distutils_src_prepare
|
||||
epatch "${FILESDIR}/${PN}-3.6.20.1-fix_tests.patch"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
distutils_src_compile --enable=load_extension
|
||||
}
|
||||
|
||||
src_test() {
|
||||
echo "$(PYTHON -f)" setup.py build_test_extension
|
||||
"$(PYTHON -f)" setup.py build_test_extension || die "Building of test loadable extension failed"
|
||||
|
||||
testing() {
|
||||
PYTHONPATH="$(ls -d build-${PYTHON_ABI}/lib.*)" "$(PYTHON)" tests.py -v
|
||||
}
|
||||
python_execute_function testing
|
||||
}
|
||||
|
||||
src_install() {
|
||||
distutils_src_install
|
||||
dodoc doc/_sources/* || die "dodoc failed"
|
||||
dohtml -r doc/* || die "dohtml failed"
|
||||
}
|
@ -1,3 +1,4 @@
|
||||
DIST Django-1.3.2.tar.gz 6507042 SHA256 72c4080fe30863c4581521ef6f7bfcc12d01e7c55b9ad1935acaa43e466dd764 SHA512 8a9d78269f9a0b84d2716f0a29d83866c670c2cec50ac48e6f4455073c4bb44d8f7828c1c3e735683daf7c7f528fd00f65f457c6e34fc538d0f6a4bbb95f88e3 WHIRLPOOL f750574297620d43e74f8ec0ddaa9dc381b2bee0fcd6afe369985652acf21d7cb07a22a242aca440b17546a8a89822bc7ef5299aeb507cd2bd94f2d1669fd374
|
||||
DIST Django-1.3.4.tar.gz 6507771 SHA256 2626e6b216e1bdef887bd923f00d94d94b4d4e75fc2e336c6f156d842d10a607 SHA512 4c207e184ec3f01754c9916757b0c621fa76c0e9ca0aa642c37403c23e2481ef4120b763d5f2b3853125ae39bdab5f956f64fce6bb4c0e8db3d48b8891124618 WHIRLPOOL 22660ff18f03014b77cd9ded24a3c78064a47e9e464092e6abc347d902b30e375e15cf6f242834a06d78eeef5b6786a0307240173d3928fa4af366cf38fbb9d9
|
||||
DIST Django-1.4.1.tar.gz 7656756 SHA256 4d8d20eba350d3d29613cc5a6302d5c23730c7f9e150985bc58b3175b755409b SHA512 1956e84c2c5131b17c76699a733801105c554d447341547c306ecf02ab1ef61371efe8fec0a8f10ddeafc9f13b61680543772678f9f1d594ad320c673669d0b2 WHIRLPOOL 38f639fa02681ab5a139bf9ce8807c0320796b7eb4e1acb498aae688a785c4ec5acaae15e9e50d8ec561be39145776d26860fbe50efab1f2dac12fa1b5504c38
|
||||
DIST Django-1.4.2.tar.gz 7722026 SHA256 edfd8733f45bbaa524cee25bcac3080ce28c21242c27227464eae3fa6b3d80e7 SHA512 5021eec3c7a48537fa15097e471232cf13d2019cfa166ff4ad50388e09ea11d85161e2e4d92927e15b1c11831286d236bd7f9817c0a2557a4bccf7b08f10751e WHIRLPOOL cf7965d7c09ae6ff54c5d3a8acf3d3348d6b008d5bdb331c37af836ec03d39cee2e7f24fb9173da155f41e290034fbb962a68d728efbfd30c05291f61cdf6682
|
||||
|
@ -0,0 +1,111 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-python/django/django-1.3.4.ebuild,v 1.2 2012/12/01 12:57:22 idella4 Exp $
|
||||
|
||||
EAPI="4"
|
||||
PYTHON_DEPEND="2"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
RESTRICT_PYTHON_ABIS="3.*"
|
||||
PYTHON_TESTS_RESTRICTED_ABIS="2.[56] 2.7-pypy-1.*"
|
||||
inherit bash-completion-r1 distutils eutils versionator webapp
|
||||
|
||||
MY_P="Django-${PV}"
|
||||
|
||||
DESCRIPTION="High-level Python web framework"
|
||||
HOMEPAGE="http://www.djangoproject.com/ http://pypi.python.org/pypi/Django"
|
||||
SRC_URI="https://www.djangoproject.com/m/releases/$(get_version_component_range 1-2)/${MY_P}.tar.gz"
|
||||
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos"
|
||||
IUSE="doc mysql postgres sqlite test"
|
||||
|
||||
RDEPEND="dev-python/imaging
|
||||
sqlite? ( || ( dev-lang/python:2.7[sqlite] dev-lang/python:2.6[sqlite] dev-lang/python:2.5[sqlite] dev-python/pysqlite:2 ) )
|
||||
postgres? ( dev-python/psycopg )
|
||||
mysql? ( >=dev-python/mysql-python-1.2.1_p2 )"
|
||||
DEPEND="${RDEPEND}
|
||||
doc? ( >=dev-python/sphinx-0.3 )
|
||||
test? ( || ( dev-lang/python:2.7[sqlite] dev-lang/python:2.6[sqlite] dev-lang/python:2.5[sqlite] dev-python/pysqlite:2 ) )"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
DOCS="docs/README AUTHORS"
|
||||
WEBAPP_MANUAL_SLOT="yes"
|
||||
|
||||
pkg_setup() {
|
||||
python_pkg_setup
|
||||
webapp_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
distutils_src_prepare
|
||||
epatch "${FILESDIR}/${PN}-1.3.1-djangodocs_extension.patch"
|
||||
|
||||
# Disable tests requiring network connection.
|
||||
sed \
|
||||
-e "s/test_correct_url_value_passes/_&/" \
|
||||
-e "s/test_correct_url_with_redirect/_&/" \
|
||||
-i tests/modeltests/validation/tests.py
|
||||
sed \
|
||||
-e "s/test_urlfield_3/_&/" \
|
||||
-e "s/test_urlfield_4/_&/" \
|
||||
-e "s/test_urlfield_10/_&/" \
|
||||
-i tests/regressiontests/forms/tests/fields.py
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
distutils_src_compile
|
||||
|
||||
if use doc; then
|
||||
einfo "Generation of documentation"
|
||||
pushd docs > /dev/null
|
||||
emake html
|
||||
popd > /dev/null
|
||||
fi
|
||||
}
|
||||
|
||||
src_test() {
|
||||
testing() {
|
||||
# Tests have non-standard assumptions about PYTHONPATH and
|
||||
# don't work with usual "build-${PYTHON_ABI}/lib".
|
||||
PYTHONPATH="." "$(PYTHON)" tests/runtests.py --settings=test_sqlite -v1
|
||||
}
|
||||
python_execute_function testing
|
||||
}
|
||||
|
||||
src_install() {
|
||||
distutils_src_install
|
||||
|
||||
newbashcomp extras/django_bash_completion ${PN}
|
||||
|
||||
if use doc; then
|
||||
rm -fr docs/_build/html/_sources
|
||||
dohtml -A txt -r docs/_build/html/*
|
||||
fi
|
||||
|
||||
insinto "${MY_HTDOCSDIR#${EPREFIX}}"
|
||||
doins -r django/contrib/admin/media/*
|
||||
|
||||
webapp_src_install
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
:
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
distutils_pkg_postinst
|
||||
|
||||
einfo "Now, Django has the best of both worlds with Gentoo,"
|
||||
einfo "ease of deployment for production and development."
|
||||
echo
|
||||
elog "A copy of the admin media is available to"
|
||||
elog "webapp-config for installation in a webroot,"
|
||||
elog "as well as the traditional location in python's"
|
||||
elog "site-packages dir for easy development"
|
||||
echo
|
||||
ewarn "If you build Django ${PV} without USE=\"vhosts\""
|
||||
ewarn "webapp-config will automatically install the"
|
||||
ewarn "admin media into the localhost webroot."
|
||||
}
|
@ -1,113 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-python/imaging/imaging-1.1.7.ebuild,v 1.15 2012/02/20 15:35:22 patrick Exp $
|
||||
|
||||
EAPI="3"
|
||||
PYTHON_DEPEND="2"
|
||||
PYTHON_USE_WITH="tk"
|
||||
PYTHON_USE_WITH_OPT="tk"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
RESTRICT_PYTHON_ABIS="3.* *-jython 2.7-pypy-*"
|
||||
|
||||
inherit eutils multilib distutils
|
||||
|
||||
MY_P=Imaging-${PV}
|
||||
|
||||
DESCRIPTION="Python Imaging Library (PIL)"
|
||||
HOMEPAGE="http://www.pythonware.com/products/pil/index.htm"
|
||||
SRC_URI="http://www.effbot.org/downloads/${MY_P}.tar.gz"
|
||||
|
||||
LICENSE="as-is"
|
||||
SLOT="0"
|
||||
KEYWORDS="alpha amd64 arm hppa ia64 ppc ppc64 sparc x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x86-solaris"
|
||||
IUSE="doc examples scanner tk X"
|
||||
|
||||
DEPEND="virtual/jpeg
|
||||
media-libs/freetype:2
|
||||
scanner? ( media-gfx/sane-backends )
|
||||
X? ( x11-misc/xdg-utils )"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
DOCS="CHANGES CONTENTS"
|
||||
|
||||
pkg_setup() {
|
||||
PYTHON_MODNAME="PIL $(use scanner && echo sane.py)"
|
||||
python_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
distutils_src_prepare
|
||||
|
||||
epatch "${FILESDIR}/${P}-no-xv.patch"
|
||||
epatch "${FILESDIR}/${P}-sane.patch"
|
||||
epatch "${FILESDIR}/${P}-giftrans.patch"
|
||||
epatch "${FILESDIR}/${P}-missing-math.patch"
|
||||
|
||||
# Add shebang.
|
||||
sed -e "1i#!/usr/bin/python" -i Scripts/pilfont.py \
|
||||
|| die "sed failed adding shebang"
|
||||
|
||||
sed -i \
|
||||
-e "s:/usr/lib\":/usr/$(get_libdir)\":" \
|
||||
-e "s:\"lib\":\"$(get_libdir)\":g" \
|
||||
setup.py || die "sed failed"
|
||||
|
||||
if ! use tk; then
|
||||
# Make the test always fail
|
||||
sed -i \
|
||||
-e 's/import _tkinter/raise ImportError/' \
|
||||
setup.py || die "sed failed"
|
||||
fi
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
distutils_src_compile
|
||||
|
||||
if use scanner; then
|
||||
pushd Sane > /dev/null
|
||||
distutils_src_compile
|
||||
popd > /dev/null
|
||||
fi
|
||||
}
|
||||
|
||||
src_test() {
|
||||
tests() {
|
||||
PYTHONPATH="$(ls -d build-${PYTHON_ABI}/lib.*)" "$(PYTHON)" selftest.py
|
||||
}
|
||||
python_execute_function tests
|
||||
}
|
||||
|
||||
src_install() {
|
||||
distutils_src_install
|
||||
|
||||
if use doc; then
|
||||
dohtml Docs/* || die "dohtml failed"
|
||||
fi
|
||||
|
||||
if use scanner; then
|
||||
pushd Sane > /dev/null
|
||||
docinto sane
|
||||
DOCS="CHANGES sanedoc.txt" distutils_src_install
|
||||
popd > /dev/null
|
||||
fi
|
||||
|
||||
# Install headers required by media-gfx/sketch.
|
||||
install_headers() {
|
||||
insinto "$(python_get_includedir)"
|
||||
doins libImaging/Imaging.h
|
||||
doins libImaging/ImPlatform.h
|
||||
}
|
||||
python_execute_function install_headers
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}/examples
|
||||
doins Scripts/* || die "doins failed"
|
||||
|
||||
if use scanner; then
|
||||
insinto /usr/share/doc/${PF}/examples/sane
|
||||
doins Sane/demo_*.py || die "doins failed"
|
||||
fi
|
||||
fi
|
||||
}
|
@ -1,3 +1 @@
|
||||
DIST jonpy-0.07.tar.gz 48845 SHA256 bbcaef6220c392d62756fe8810b31de08f311bae5760c72cbac6376090d7979b SHA512 d37f016a5c001f9cf1256bf8c621d43e9e812b4aae906b11ccdf104c179d60f9b1e091c80bb805b84452cc315ed605fb0ba5708595e962f85135786e3967c0a2 WHIRLPOOL 7c5b1a06d106755c6fc7c83139b7d66565348c73d05568e759cc473a4b43a4a4a7b1a8f326535ab79a5a0f8b88f5aca1662db0734741626c2240142817b51013
|
||||
DIST jonpy-0.09.tar.gz 51280 SHA256 d14f848a6b129431a040dbb3c09aaffe817379d69823521c671a42bb129bc442 SHA512 85f54460bb2c32284e9300bf04b973e47f3e37b47bdd5eb7009cb8fc39c8e29f43ce82c5579c4836decc8bb06e8b5b097d93c7f87ef491cde9cf4ee1753ea842 WHIRLPOOL 21109bfa7f687a4880f34dfb0cfc0b3532964a117782e07e8bed6c6c94b836b676844ab693d4c3e4f06c0ffec9f4dbed9597ed73a3637f25f96283a8ae312e60
|
||||
DIST jonpy-0.10.tar.gz 51672 SHA256 33f43845b6403a2596d89e2210ba043d73facd39937e04eb59d0b7ef683b9456 SHA512 2dcea6798e186a1bfd767f3a0b331ee5ca56e2c0df63b8ac1f3ac53c9906ca98387a0d47166c11057cee62dc669de0771eba6e72d59d5ecd0e88b2fcd5b70281 WHIRLPOOL 8a9e7334d31f822bab462cee321bb520922f070ca569588881ed741ebf0580967d2222f1caf521941a3db3bd8b801f825e485c11dd481a5c66975e293878666f
|
||||
|
@ -1,36 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-python/jonpy/jonpy-0.07.ebuild,v 1.5 2012/07/01 18:16:57 armin76 Exp $
|
||||
|
||||
EAPI="2"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
|
||||
inherit distutils
|
||||
|
||||
DESCRIPTION="Powerful multi-threaded object-oriented CGI/FastCGI/mod_python/html-templating facilities"
|
||||
HOMEPAGE="http://jonpy.sourceforge.net/"
|
||||
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
|
||||
|
||||
LICENSE="as-is"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 x86"
|
||||
IUSE="doc examples"
|
||||
|
||||
DEPEND=""
|
||||
RDEPEND=""
|
||||
RESTRICT_PYTHON_ABIS="3.*"
|
||||
|
||||
PYTHON_MODNAME="jon"
|
||||
|
||||
src_install() {
|
||||
distutils_src_install
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}
|
||||
doins -r example
|
||||
fi
|
||||
|
||||
if use doc; then
|
||||
dohtml doc/*
|
||||
fi
|
||||
}
|
@ -1,37 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-python/jonpy/jonpy-0.09.ebuild,v 1.4 2012/07/01 18:16:57 armin76 Exp $
|
||||
|
||||
EAPI="3"
|
||||
PYTHON_DEPEND="2"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
RESTRICT_PYTHON_ABIS="3.*"
|
||||
|
||||
inherit distutils
|
||||
|
||||
DESCRIPTION="Powerful multi-threaded object-oriented CGI/FastCGI/mod_python/html-templating facilities"
|
||||
HOMEPAGE="http://jonpy.sourceforge.net/ http://pypi.python.org/pypi/jonpy"
|
||||
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
|
||||
|
||||
LICENSE="as-is"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 x86"
|
||||
IUSE="doc examples"
|
||||
|
||||
DEPEND=""
|
||||
RDEPEND=""
|
||||
|
||||
PYTHON_MODNAME="jon"
|
||||
|
||||
src_install() {
|
||||
distutils_src_install
|
||||
|
||||
if use doc; then
|
||||
dohtml doc/*
|
||||
fi
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}
|
||||
doins -r example
|
||||
fi
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue