Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 259995

Summary: [PATCH] net-p2p/transmission-1.42
Product: Gentoo/Alt Reporter: Ian Cullinan <cibyr>
Component: Prefix SupportAssignee: Gentoo Prefix <prefix>
Status: RESOLVED FIXED    
Severity: enhancement    
Priority: High    
Version: unspecified   
Hardware: x86   
OS: Solaris   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: Fixed ebuild
Patch so that transmission builds properly (instead of screwing up on /usr/include/utility.h)

Description Ian Cullinan 2009-02-23 11:44:10 UTC
Used ecopy, then added a patch to #define MIN() instead of including <utility.h>, which causes problems. Had to emerge gettext, libcurl and intltool before it would build, so I guess that needs to be fixed up in DEPEND but I don't know how to do it.

Reproducible: Always

Steps to Reproduce:
1. ecopy net-p2p/transmission
2. 
--- transmission-1.42.orig/third-party/miniupnp/miniwget.c      2009-02-23 21:26:24.708690462 +1000
+++ transmission-1.42/third-party/miniupnp/miniwget.c   2009-02-23 21:27:24.249090843 +1000
@@ -26,9 +26,9 @@
 #include <arpa/inet.h>
 #define closesocket close
 #endif
-/* for MIN() macro : */
+
 #if defined(__sun) || defined(sun)
-#include <utility.h>
+#define MIN(x,y) (((x)<(y))?(x):(y))
 #endif
3. Profit!

Actual Results:  
$ ebuild transmission-1.42.ebuild test -> All tests passed.


$ emerge --info
Portage 2.2.00.12671-prefix (prefix/sunos/solaris/5.11/x86, gcc-4.2.4, unavailable, 5.11 i86pc)
=================================================================
System uname: Solaris-2.11-i86pc-i386-32bit-ELF
Timestamp of tree: Sun, 22 Feb 2009 04:31:59 +0000
app-shells/bash:     3.2_p48-r1
dev-lang/python:     2.5.4-r2
dev-python/pycrypto: 2.0.1-r6
sys-devel/autoconf:  2.63
sys-devel/automake:  1.10.2-r00.1
sys-devel/binutils:  2.19.1
sys-devel/gcc-config: 1.4.0-r04.6
sys-devel/libtool:   1.5.26
ACCEPT_KEYWORDS="~x86-solaris"
CBUILD="i386-pc-solaris2.11"
CFLAGS=""
CHOST="i386-pc-solaris2.11"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/terminfo"
CXXFLAGS=""
DISTDIR="/opt/gentoo/usr/portage/distfiles"
EPREFIX="/opt/gentoo"
FEATURES="collision-protect distlocks fixpackages nostrip parallel-fetch preserve-libs protect-owned sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://mirror.internode.on.net/pub/gentoo/ ftp://mirror.internode.on.net/pub/gentoo/ http://public.planetmirror.com/pub/gentoo/ http://mirror.pacific.net.au/linux/Gentoo http://mirror.isp.net.au/ftp/pub/gentoo/ "
LANG="en_AU.UTF-8"
LDFLAGS=""
PKGDIR="/opt/gentoo/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/opt/gentoo/var/tmp"
PORTDIR="/opt/gentoo/usr/portage"
PORTDIR_OVERLAY="/opt/gentoo/usr/local/portage"
SYNC="rsync://rsync.prefix.freens.org/gentoo-portage-prefix"
USE="cracklib midi ncurses prefix python readline ssl x86-solaris zlib" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="SunOS" INPUT_DEVICES="keyboard mouse" KERNEL="SunOS" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LC_ALL, LINGUAS, MAKEOPTS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Ian Cullinan 2009-02-23 11:46:45 UTC
Created attachment 182871 [details]
Fixed ebuild

Still needs DEPEND fixed, I think. Better than nothing though.
Comment 2 Ian Cullinan 2009-02-23 11:47:52 UTC
Created attachment 182872 [details, diff]
Patch so that transmission builds properly (instead of screwing up on /usr/include/utility.h)
Comment 3 Fabian Groffen gentoo-dev 2009-03-22 10:42:20 UTC
(In reply to comment #0)
> ...  Had to emerge gettext, libcurl and intltool
> before it would build, so I guess that needs to be fixed up in DEPEND but I
> don't know how to do it.

Seems curl, gettext and intltool are already in the dependencies of the ebuild these days.

I hit the same error on Solaris 10, and your patch works.  Could you please check this against 1.51 and if it still applies, notify upstream?