Opened 19 years ago

Closed 19 years ago

Last modified 19 years ago

#342 closed defect (fixed)

vo_sdl.c and ao_sdl.c redefine setenv() when Solaris 10 defines it in stdlib.h

Reported by: chrisalbertson90278@… Owned by: diego@…
Priority: normal Component: build system
Version: 1.0pre7 Severity: normal
Keywords: Cc:
Blocked By: Blocking:
Reproduced by developer: no Analyzed by developer: no

Description

There is a no longer valid test in two files, vo_sdl.c and ao_sdl.c
The test assumes setenv() is undefined if the OS is Solaris. Solaris 10
defines setenv() in stdlib.h

The correct fix would be to check for setenv() in the configure script
then use #if HAVESETENV in the above two .c files. I used a quick hack
and edited the two source files to red "#if 0" and got MPlayer to build
on Solaris 10.

defined(MINGW32)
defined(HPUX) defined(sgi) (defined(sun) &&

defined(svr4))
/* setenv is missing on win32, solaris, IRIX and HPUX */

Also the exact same code used to define setenv()is in both vo_sdl.c and ao_sdl.c
this maybe should be moved to a common place. I don't know MPlayer well enough
to suggest where

Attachments (2)

setenv.patch (2.7 KB ) - added by diego@… 19 years ago.
setenv implementation in osdep/
setenv.2.patch (3.6 KB ) - added by diego@… 19 years ago.
correct version of patch

Download all attachments as: .zip

Change History (7)

comment:1 by diego@…, 19 years ago

Component: aobuild system
Owner: changed from alex@… to diego@…

comment:2 by diego@…, 19 years ago

Status: newassigned

by diego@…, 19 years ago

Attachment: setenv.patch added

setenv implementation in osdep/

comment:3 by diego@…, 19 years ago

Please check if the attached patch fixes your problem.

by diego@…, 19 years ago

Attachment: setenv.2.patch added

correct version of patch

comment:4 by diego@…, 19 years ago

attachments.isobsolete: 01

The last patch was missing a hunk, try this one instead.

comment:5 by diego@…, 19 years ago

Resolution: fixed
Status: assignedclosed

An equivalent patch was applied to CVS, this should be fixed now.

Note: See TracTickets for help on using tickets.