Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 458504 - Stabilize =games-arcade/sdl-sopwith-1.7.5-r1
Summary: Stabilize =games-arcade/sdl-sopwith-1.7.5-r1
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Keywording and Stabilization (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Gentoo Games
URL:
Whiteboard:
Keywords: STABLEREQ
Depends on:
Blocks:
 
Reported: 2013-02-20 22:15 UTC by Mr. Bones. (RETIRED)
Modified: 2013-02-25 12:17 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
sopwith-video.patch (sopwith-video.patch,546 bytes, patch)
2013-02-21 16:04 UTC, Denis M. (Phr33d0m)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mr. Bones. (RETIRED) gentoo-dev 2013-02-20 22:15:06 UTC
Please mark sdl-sopwith-1.7.5.ebuild stable.
Comment 1 Sergey Popov gentoo-dev 2013-02-20 22:54:39 UTC
I have got:

pinkbyte@phantom ~ $ sopwith 
swloadconf: cant open /home/pinkbyte/.sopwithrc: No such file or directory
CGA Screen Emulation
Segmentation fault

emerge --info of the test system:

Portage 2.1.11.31 (default/linux/amd64/13.0, gcc-4.6.3, glibc-2.15-r3, 3.7.3-gentoo-BADO x86_64)
=================================================================
System uname: Linux-3.7.3-gentoo-BADO-x86_64-Intel-R-_Core-TM-_i7_CPU_950_@_3.07GHz-with-gentoo-2.1
Timestamp of tree: Tue, 19 Feb 2013 22:45:01 +0000
ld GNU ld (GNU Binutils) 2.22
app-shells/bash:          4.2_p37
dev-lang/python:          2.7.3-r2, 3.2.3
dev-util/cmake:           2.8.9
dev-util/pkgconfig:       0.27.1
sys-apps/baselayout:      2.1-r1
sys-apps/openrc:          0.11.8
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.68
sys-devel/automake:       1.11.6
sys-devel/binutils:       2.22-r1
sys-devel/gcc:            4.6.3
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4-r1
sys-devel/make:           3.82-r4
sys-kernel/linux-headers: 3.6 (virtual/os-headers)
sys-libs/glibc:           2.15-r3
Repositories: gentoo pinkbyte
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/bound/distfiles"
EMERGE_DEFAULT_OPTS=""
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://mirror.yandex.ru/gentoo-distfiles"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,--hash-style=gnu"
MAKEOPTS="-j9"
PKGDIR="/bound/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/bound/portage"
PORTDIR_OVERLAY="/bound/overlays/pinkbyte"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="acl amd64 bzip2 cli cracklib crypt cxx dri fortran gpm iconv ipv6 mmx modules mudflap multilib ncurses nls nptl openmp pam pcre readline session sse sse2 ssl tcpd threads unicode zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" 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="authn_core authz_core socache_shmcb unixd 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 cgi cgid 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" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="ru ru_RU" PHP_TARGETS="php5-3" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7" RUBY_TARGETS="ruby18 ruby19" USERLAND="GNU" VIDEO_CARDS="nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
USE_PYTHON="2.7"
Unset:  CPPFLAGS, CTARGET, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 2 Denis M. (Phr33d0m) 2013-02-21 13:00:42 UTC
Aside from bug 458586, amd64 ok here.
I'm unable to reproduce the segfault Sergey is having. Are you in the 'games' group? Can we get a backtrace please?
Comment 3 Sergey Popov gentoo-dev 2013-02-21 14:19:05 UTC
(In reply to comment #2)
> Are you in the 'games' group? 

yep.

pinkbyte@phantom ~ $ id
uid=1000(pinkbyte) gid=1000(pinkbyte) groups=1000(pinkbyte),35(games)

> Can we get a backtrace please?

sure.

pinkbyte@phantom ~ $ gdb sopwith
GNU gdb (Gentoo 7.5 p1) 7.5
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.gentoo.org/>...
Reading symbols from /usr/games/bin/sopwith...done.
(gdb) run
Starting program: /usr/games/bin/sopwith 
warning: Could not load shared library symbols for linux-vdso.so.1.
Do you need "set solib-search-path" or "set sysroot"?
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
swloadconf: cant open /home/pinkbyte/.sopwithrc: No such file or directory
CGA Screen Emulation

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff7bc4161 in SDL_WM_SetIcon () from /usr/lib64/libSDL-1.2.so.0
(gdb) bt
#0  0x00007ffff7bc4161 in SDL_WM_SetIcon () from /usr/lib64/libSDL-1.2.so.0
#1  0x000000000040cbbc in set_icon (sym=0x628df0) at video.c:216
#2  0x000000000040d44f in Vid_SetMode () at video.c:374
#3  0x000000000040d654 in Vid_Init () at video.c:438
#4  0x000000000040a616 in swinit (argc=1, argv=0x7fffffffe488) at swinit.c:1178
#5  0x000000000040bdcd in main (argc=1, argv=0x7fffffffe488) at swmain.c:135
Comment 4 Sergey Popov gentoo-dev 2013-02-21 14:50:58 UTC
I have discovered crash problem - it crashes with media-libs/libsdl[-X], so i think dependency on libsdl should be adjusted
Comment 5 Denis M. (Phr33d0m) 2013-02-21 15:04:56 UTC
Btw, upstream has been notified (via email) about this issue.
Comment 6 Denis M. (Phr33d0m) 2013-02-21 16:04:23 UTC
Created attachment 339604 [details, diff]
sopwith-video.patch

(In reply to comment #4)
> i think dependency on libsdl should be adjusted

Upstream has been very fast to reply my email. He sent me a patch that will (most probably) fix this issue.

Sergey, please test it out and lets see if it works. If it does, then we won't need to hard-bind to X.


--- src/sdl/video.c.orig	2013-02-21 11:48:57.000000000 -0400
+++ src/sdl/video.c	2013-02-21 11:49:35.000000000 -0400
@@ -364,11 +364,17 @@
 	int n;
 	int w, h;
 	int flags = 0;
+        int status;
 
 	printf("CGA Screen Emulation\n");
 	printf("init screen: ");
 
-	SDL_Init(SDL_INIT_VIDEO);
+	status = SDL_Init(SDL_INIT_VIDEO);
+        if (status == -1)
+        {
+          fprintf(stderr, "Unable to locate video device. Exiting.\n");
+          exit(1);
+        }
 	srand(time(NULL));
 	set_icon(symbol_plane[rand() % 2][rand() % 16]);
Comment 7 Sergey Popov gentoo-dev 2013-02-21 18:25:02 UTC
> Sergey, please test it out and lets see if it works. If it does, then we
> won't need to hard-bind to X.

Works good, let's stable new revision

+  21 Feb 2013; Sergey Popov <pinkbyte@gentoo.org> +sdl-sopwith-1.7.5-r1.ebuild,
+  +files/sdl-sopwith-1.7.5-video-fix.patch:
+  Revision bump: add fix for segfault issue during video device detection,
+  discovered in bug #458504
Comment 8 Sergey Popov gentoo-dev 2013-02-21 18:25:47 UTC
amd64 stable
Comment 9 Agostino Sarubbo gentoo-dev 2013-02-22 17:23:59 UTC
ppc stable
Comment 10 Agostino Sarubbo gentoo-dev 2013-02-25 12:17:50 UTC
x86 stable. Last arch, closing