I have just emerged the new quake3-1.33_alpha177 ebuild. The emerge completes fine, but when I try to run quake3, pax kills it. Reproducible: Always Steps to Reproduce: 1. echo "games-fps/quake3 ~x86" > /etc/portage/package.keywords 2. emerge quake3 3. quake3 Actual Results: I get output to the terminal (see attachments). The screen blanks for about half a second during this process. Expected Results: Quake3 should have sucessfully started. I will also attach a stack trace. I also have core files (about 108 Mb) available. The quake3 binary package worked fine. The relevant pax.log output is: Oct 26 20:55:02 scleaross PAX: execution attempt in: <anonymous mapping>, 43660000-46e61000 43660000 Oct 26 20:55:02 scleaross PAX: terminating task: /usr/games/bin/quake3(quake3):26264, uid/euid: 1024/1024, PC: 438b9320, SP: 520c7d4c Oct 26 20:55:02 scleaross PAX: bytes at PC: 81 ee 1c 00 00 00 83 c7 04 8d 86 10 00 00 00 89 07 83 c7 04 Oct 26 20:55:02 scleaross PAX: bytes at SP: 13f39cd7 520c7da0 000fffd0 520c8dc8 520c7d70 13f78e2c 14753a80 520c8ef4 520c7da4 00000000 00000000 00000000 00000000 00000000 520c7e4c 00000000 000fffd0 14753a80 257310e8 00000000 emerge --info: Gentoo Base System version 1.6.13 Portage 2.0.51.22-r3 (hardened/x86/2.6, gcc-3.3.6, glibc-2.3.5-r2, 2.6.11-hardened-r15 i686) ================================================================= System uname: 2.6.11-hardened-r15 i686 AMD Sempron(tm) 2400+ ccache version 2.3 [enabled] dev-lang/python: 2.3.5-r2, 2.4.2 sys-apps/sandbox: 1.2.12 sys-devel/autoconf: 2.13, 2.59-r6 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1 sys-devel/binutils: 2.15.92.0.2-r10 sys-devel/libtool: 1.5.20 virtual/os-headers: 2.6.11-r2 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-O2 -march=athlon-xp -pipe -fforce-addr" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-O2 -march=athlon-xp -pipe -fforce-addr" DISTDIR="/usr/local/src" FEATURES="autoconfig ccache distlocks nostrip sandbox sfperms strict" GENTOO_MIRRORS="http://mirror.pacific.net.au/linux/Gentoo http://mirror.isp.net.au/ftp/pub/gentoo http://planetmirror.com/pub/gentoo http://gentoo.osuosl.org http://www.ibiblio.org/pub/Linux/distributions/gentoo" LC_ALL="en_AU" MAKEOPTS="-j2" PKGDIR="/usr/portage//packages/x86/" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/var/portage" PORTDIR_OVERLAY="/usr/local/portage" SYNC="rsync://rsync.au.gentoo.org/gentoo-portage" USE="X acpi alsa avi bash-completion berkdb caps cdparanoia cdr cjk crypt cups curl dlloader dvd emacs esd fam flac foomaticdb gcj gdbm gif gmp gpm gtk gtk2 hardened imap imlib jpeg libwww maildir mbox mime mng motif ncurses nls nptl nptlonly offensive ogg oggvorbis opengl pam perl pic pie png ppds python readline samba sdl sockets speex ssl svga tcltk tcpd tetex theora threads tiff timidity truetype udev usb userlocales vorbis win32codecs x86 xine xml2 xmms xv zlib userland_GNU kernel_linux elibc_glibc" Unset: ASFLAGS, CTARGET, LANG, LDFLAGS, LINGUAS
Created attachment 71491 [details] Terminal output of quake3
Created attachment 71492 [details] strace of quake3
try changing to /usr/games/lib/quake3 and then run quake3
That fixes that problem. I do think that there should be a wrapper script put in place to handle this issue , as there is no other indication that one needs to follow these steps. Also, there is no mention of having to put pak0.pk3 in the right folder, like there was for the old binary qauke3. I now have a similar problem. The game runs, but whenever I try to start a map, pax kills it: Oct 26 23:34:26 scleaross PAX: execution attempt in: <NULL>, 00000000-00000000 00000000 Oct 26 23:34:26 scleaross PAX: terminating task: /usr/games/bin/quake3(quake3):5840, uid/euid: 1024/1024, PC: 00000000, SP: 53faf2fc Oct 26 23:34:26 scleaross PAX: bytes at PC: <invalid address>. Oct 26 23:34:26 scleaross PAX: bytes at SP: 170a71b1 00000027 53faf340 00000000 53faf310 7f615173 00000000 00000000 00000000 00000000 1712fe2c 53faf378 170a66e8 00000023 1712fe2c 53faf388 1704162b 00000000 00000000 1706781b
no, quake3 should search that libpath ... for some reason, it 'just works' on my box so i didnt look into that ... i'll come up with a patch though
did the binary quake3 client always work in PaX ? i.e. playing on multiplayer servers and such ?
I only tried playing on a non-local server once with the binary, and it worked flawlessly. I also had it work flawlessly for many local servers.
if you use chpax on the quake3 binary, does it work ? try like: chpax -pemrxs /usr/gmaes/bin/quake3
I use paxctl, not chpax. After trying that, almost everything is the same excpet that it now segfaults instead of being killed by pax. If I cd to /usr/games/lib/quake3 and run, then I get to the same place I did before and it segfaults. So basically, it now segfaults whenever pax would have killed it before.
just updated the snapshot, give it a spin
That fixes the first issue. However, now it gets killed by pax whenever I try to start a game, as described in comment #4. Should this be files in a new bug or continued here?
might as well keep it here since you've always had the same problem, the lib search path was just a red herring can you rebuild quake3 with debug flags and see if you can get a useful gdb trace out of it ?
I'd just like to confirm this bug I'm using version 187 fireburn@quark ~ $ quake3 +set fs_cdpath /mnt/iso/Quake3/ +set s_system oss ioQ3 1.33 linux-i386 Oct 27 2005 ----- FS_Startup ----- Current search path: /home/fireburn/.q3a/baseq3 /usr/share/games/quake3/baseq3/pak8.pk3 (9 files) /usr/share/games/quake3/baseq3/pak7.pk3 (4 files) /usr/share/games/quake3/baseq3/pak6.pk3 (64 files) /usr/share/games/quake3/baseq3/pak5.pk3 (7 files) /usr/share/games/quake3/baseq3/pak4.pk3 (272 files) /usr/share/games/quake3/baseq3/pak3.pk3 (4 files) /usr/share/games/quake3/baseq3/pak2.pk3 (148 files) /usr/share/games/quake3/baseq3/pak1.pk3 (26 files) /usr/share/games/quake3/baseq3 /mnt/iso/Quake3//baseq3/pak1.pk3 (7 files) /mnt/iso/Quake3//baseq3/pak0.pk3 (3539 files) /mnt/iso/Quake3//baseq3 ---------------------- 4080 files in pk3 files execing default.cfg execing q3config.cfg couldn't exec autoexec.cfg Hunk_Clear: reset the hunk ok ----- Client Initialization ----- ----- Initializing Renderer ---- ------------------------------- ----- Client Initialization Complete ----- ----- R_Init ----- ------- Input Initialization ------- Joystick is not active. ------------------------------------ ...loading libGL.so.1: Calling SDL_Init(SDL_INIT_VIDEO)... SDL_Init(SDL_INIT_VIDEO) passed. Initializing OpenGL display ...setting mode 3: 640 480 Using 8/8/8 Color bits, 24 depth, 0 stencil display. GL_RENDERER: GeForce 6600/AGP/SSE/3DNOW! Initializing OpenGL extensions ...ignoring GL_S3_s3tc ...ignoring GL_EXT_texture_env_add ...using GL_ARB_multitexture ...using GL_EXT_compiled_vertex_array GL_VENDOR: NVIDIA Corporation GL_RENDERER: GeForce 6600/AGP/SSE/3DNOW! GL_VERSION: 2.0.0 NVIDIA 76.76 GL_EXTENSIONS: GL_ARB_color_buffer_float GL_ARB_depth_texture GL_ARB_draw_buffers GL_ARB_fragment_program GL_ARB_fragment_program_shadow GL_ARB_fragment_shader GL_ARB_half_float_pixel GL_ARB_imaging GL_ARB_multisample GL_ARB_multitexture GL_ARB_occlusion_query GL_ARB_point_parameters GL_ARB_point_sprite GL_ARB_shadow GL_ARB_shader_objects GL_ARB_shading_language_100 GL_ARB_texture_border_clamp GL_ARB_texture_compression GL_ARB_texture_cube_map GL_ARB_texture_env_add GL_ARB_texture_env_combine GL_ARB_texture_env_dot3 GL_ARB_texture_float GL_ARB_texture_mirrored_repeat GL_ARB_texture_non_power_of_two GL_ARB_texture_rectangle GL_ARB_transpose_matrix GL_ARB_vertex_buffer_object GL_ARB_vertex_program GL_ARB_vertex_shader GL_ARB_window_pos GL_ATI_draw_buffers GL_ATI_texture_float GL_ATI_texture_mirror_once GL_S3_s3tc GL_EXT_texture_env_add GL_EXT_abgr GL_EXT_bgra GL_EXT_blend_color GL_EXT_blend_equation_separate GL_EXT_blend_func_separate GL_EXT_blend_minmax GL_EXT_blend_subtract GL_EXT_compiled_vertex_array GL_EXT_Cg_shader GL_EXT_depth_bounds_test GL_EXT_draw_range_elements GL_EXT_fog_coord GL_EXT_framebuffer_object GL_EXT_multi_draw_arrays GL_EXT_packed_pixels GL_EXT_pixel_buffer_object GL_EXT_point_parameters GL_EXT_rescale_normal GL_EXT_secondary_color GL_EXT_separate_specular_color GL_EXT_shadow_funcs GL_EXT_stencil_two_side GL_EXT_stencil_wrap GL_EXT_texture3D GL_EXT_texture_compression_s3tc GL_EXT_texture_cube_map GL_EXT_texture_edge_clamp GL_EXT_texture_env_combine GL_EXT_texture_env_dot3 GL_EXT_texture_filter_anisotropic GL_EXT_texture_lod GL_EXT_texture_lod_bias GL_EXT_texture_mirror_clamp GL_EXT_texture_object GL_EXT_vertex_array GL_HP_occlusion_test GL_IBM_rasterpos_clip GL_IBM_texture_mirrored_repeat GL_KTX_buffer_region GL_NV_blend_square GL_NV_copy_depth_to_color GL_NV_depth_clamp GL_NV_fence GL_NV_float_buffer GL_NV_fog_distance GL_NV_fragment_program GL_NV_fragment_program_option GL_NV_fragment_program2 GL_NV_half_float GL_NV_light_max_exponent GL_NV_multisample_filter_hint GL_NV_occlusion_query GL_NV_packed_depth_stencil GL_NV_pixel_data_range GL_NV_point_sprite GL_NV_primitive_restart GL_NV_register_combiners GL_NV_register_combiners2 GL_NV_texgen_reflection GL_NV_texture_compression_vtc GL_NV_texture_env_combine4 GL_NV_texture_expand_normal GL_NV_texture_rectangle GL_NV_texture_shader GL_NV_texture_shader2 GL_NV_texture_shader3 GL_NV_vertex_array_range GL_NV_vertex_array_range2 GL_NV_vertex_program GL_NV_vertex_program1_1 GL_NV_vertex_program2 GL_NV_vertex_program2_option GL_NV_vertex_program3 GL_NVX_conditional_render GL_SGIS_generate_mipmap GL_SGIS_texture_lod GL_SGIX_depth_texture GL_SGIX_shadow GL_SUN_slice_accum GL_MAX_TEXTURE_SIZE: 4096 GL_MAX_ACTIVE_TEXTURES_ARB: 4 PIXELFORMAT: color(24-bits) Z(24-bit) stencil(0-bits) MODE: 3, 640 x 480 fullscreen hz:N/A GAMMA: hardware w/ 0 overbright bits CPU: rendering primitives: single glDrawElements texturemode: GL_LINEAR_MIPMAP_NEAREST picmip: 1 texture bits: 0 multitexture: enabled compiled vertex arrays: enabled texenv add: disabled compressed textures: disabled Initializing Shaders ...loading 'scripts/lightningnew.shader' ...loading 'scripts/explode1.shader' ...loading 'scripts/gfx.shader' ...loading 'scripts/tim.shader' ...loading 'scripts/base.shader' ...loading 'scripts/base_button.shader' ...loading 'scripts/base_floor.shader' ...loading 'scripts/base_light.shader' ...loading 'scripts/base_object.shader' ...loading 'scripts/base_support.shader' ...loading 'scripts/base_trim.shader' ...loading 'scripts/base_wall.shader' ...loading 'scripts/common.shader' ...loading 'scripts/ctf.shader' ...loading 'scripts/eerie.shader' ...loading 'scripts/gothic_block.shader' ...loading 'scripts/gothic_floor.shader' ...loading 'scripts/gothic_light.shader' ...loading 'scripts/gothic_trim.shader' ...loading 'scripts/gothic_wall.shader' ...loading 'scripts/hell.shader' ...loading 'scripts/liquid.shader' ...loading 'scripts/menu.shader' ...loading 'scripts/models.shader' ...loading 'scripts/organics.shader' ...loading 'scripts/sfx.shader' ...loading 'scripts/shrine.shader' ...loading 'scripts/skin.shader' ...loading 'scripts/sky.shader' ...loading 'scripts/test.shader' ----- finished R_Init ----- ------- sound initialization ------- SDL Audio driver initializing... Calling SDL_Init(SDL_INIT_AUDIO)... SDL_Init(SDL_INIT_AUDIO) passed. SDL audio driver is "alsa" Format we requested from SDL audio device: Format: AUDIO_S16LSB Freq: 22050 Samples: 512 Channels: 2 Format we actually got: Format: AUDIO_S16LSB Freq: 22050 Samples: 512 Channels: 2 WARNING: sdlmixsamps wasn't a power of two (10240), so we made it one (16384). Starting SDL audio callback... SDL audio initialized. ------------------------------------ ----- Sound Info ----- 1 stereo 16384 samples 16 samplebits 1 submission_chunk 22050 speed 0x8aa36c8 dma buffer No background file. ---------------------- Sound memory manager started Loading vm file vm/ui.qvm... VM file ui compiled to 594408 bytes of code ui loaded in 1963008 bytes on the hunk Received signal 11, exiting... ----- CL_Shutdown ----- Segmentation fault fireburn@quark ~ $ emerge info Portage 2.0.53_rc6 (default-linux/x86/2005.0, gcc-4.0.2, glibc-2.3.5.20050722-r0, 2.6.13-gentoo-r5 i686) ================================================================= System uname: 2.6.13-gentoo-r5 i686 AMD Athlon(TM) XP 2500+ Gentoo Base System version 1.12.0_pre9 dev-lang/python: 2.4.2 sys-apps/sandbox: 1.2.13 sys-devel/autoconf: 2.13, 2.59-r7 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1 sys-devel/binutils: 2.16.91.0.3 sys-devel/libtool: 1.5.20 virtual/os-headers: 2.6.11-r2 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-march=athlon-xp -mtune=athlon-xp -Os -mfpmath=sse,387 -fvisibility-inlines-hidden -w -fPIC" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /etc/env.d /usr/kde/2/share/config /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/X11/xkb /usr/share/config /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/splash /etc/terminfo /etc/env.d" CXXFLAGS="-march=athlon-xp -mtune=athlon-xp -Os -mfpmath=sse,387 -fvisibility-inlines-hidden -w -fPIC -fpermissive" DISTDIR="/usr/portage/distfiles" FEATURES="autoconfig distlocks sandbox sfperms strict" GENTOO_MIRRORS="http://gentoo.blueyonder.co.uk/ http://www.mirror.ac.uk/mirror/distro.ibiblio.org/pub/linux/distributions/gentoo/" LANG="en_GB.ISO8859-1" LC_ALL="en_GB.ISO8859-1" LDFLAGS="-Wl,-O1 -Wl,--sort-common -z combreloc -Wl,--enable-new-dtags -Wl,--relax" LINGUAS="en_GB" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/home/fireburn/Portage" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="3dnow 3dnowext 3ds X a52 aac aalib acpi alsa apm arts artswrappersuid artworkextra async audiofile automount avi bash-completion berkdb bidi bitmap-fonts bl bluetooth browserplugin bzlib cairo cdda cddb cdinstall cdio cdparanoia cdr css cups curl custom-cflags dbus dga directfb dmx dpms dts dvb dvd dvdr dvdread emboss encode esd faad fam fame fbcon fbsplash ffmpeg flac flash foomaticdb fortran freetype freetype2 gdbm gif glibc-omitfp glitz gphoto2 gpm gstreamer gtk gtk2 hal imagemagick imlib irmc ithreads java javascript joystick jpeg jpeg2k kde kdeenablefinal kdgraphics libg++ libwww linuxthreads-tls lm_sensors mad mikmod mmx mmxext mng motif mozcalendar mozdevelop mozilla mozpango mozsvg mp3 mpeg mpeg2 msn musepack musicbrainz ncurses network no_wxgtk1 nomalloccheck nptl nptlonly nsplugin nv nvidia offensive ogg oggvorbis openal opengl pam pam_chroot pam_console pdflib perl pic png portaudio python qt quicktime rdesktop readline real remote rtc samba sametime sdl sensord slang sndfile speex spell sse ssl stream svga sysfs syslog tcltk tcpd tga theora threads tidy tiff transcode truetype truetype-fonts type1-fonts udev userlocales v4l vcd vcdimager vidix vorbis wifi win32codecs wmf x86 xanim xine xml xml2 xmms xprint xscreensaver xv xvid xvmc yv12 zeroconf zlib linguas_en_GB userland_GNU kernel_linux elibc_glibc" Unset: ASFLAGS, CTARGET
About rebuilding with debug flags and getting a trace from gdb, I'm not very good at that sort of thing. Is it possible you can give steps (or point me somewhere)? Sorry.
I still haven't managed to get a useful gdb trace (the backtrace command tells me "No Stack"). While trying to get a stack trace, I recompiled with the vanilla specs (and the -g CFLAG, though I think this is irrelevant) instead of the hardened specs I usually use. Pax still kills it, but I found that if I take away the Pax protections, then it seems to run fine, rather than segfault as it was before. This seems weird, given that the other reporter doesn't use hardened. I still don't know what I am doing regarding trying to get a stack trace, it would help if someone told me what I was supposed to be doing.
Actually, it doesn't work completely fine, there is a delay of about 0.75s in sound effects.
build it with CFLAGS='-g' and FEATURES='nostrip' then run `gdb quake3` and type 'bt' when it segfaults can you try checking if you can unpack the tarball and build it yourself (just run `make` in the topdir) if the resulting binary works
Compiling with CFLAGS=-g and not stripping, Quake3 gets killed by pax (SIGKILL), and bt spits out "no stack". Removing pax protections from the binary causes quake3 to lock up when I try to start a map. I have to ctrl+alt+f1 and kill quake3 to get X back. gdb then says "Program received signal SIGSEGV, Segmentation fault. 0x00000000 in ?? ()" even though I specifically sent it a 9 (SIGKILL). bt gets it to say "#0 0x00000000 in ?? () Cannot access memory at address 0xafff914c" If I compile the program myself, I get the same symptoms (except a differenet address where it said 0xafff914c before.
try putting '-fno-strict-aliasing' into your CFLAGS ...
Adding -fno-strict-aliasing to my CFLAGS changes nothing.
Running quake3 with the following settings seems to get it working +set sv_pure 0 +set vm_cgame 0 +set vm_game 0 +set vm_ui 0 This is from the README file Using shared libraries instead of qvm ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ To make quake3 prefer shared libraries instead of qvm run it with the following parameters: +set sv_pure 0 +set vm_cgame 0 +set vm_game 0 +set vm_ui 0
Actually +set sv_pure 0 +set vm_cgame 0 +set vm_game 1 +set vm_ui 1 seems to give the best results for playing the game
Really old. reopen if this is still a problem.