[MPlayer-dev-eng] [PATCH] replace glibc basename by macro to fix --enable-menu on Cygwin

Frederick Bruckman fredb at immanent.net
Wed Jan 15 02:25:09 CET 2003


On Wed, 15 Jan 2003, Diego Biurrun wrote:

> I noticed some time ago that --enable-menu fails to compile on Cygwin
> because menu_pt.c #includes libgen.h that is part of glibc and not
> available under Cygwin.  I therefore ripped the macro mp_basename out of
> mplayer.c and put it in menu_pt.c instead of libgen.h.  It compiles, it
> works.  I probably got it all wrong, so please tell me what I have to do
> differently.  Anyway, here is the patch.

According to my docs's, basename() is POSIX (IEEE Std 1003.1-2001).
IMHO (as I am Not an MPlayer Developer), it would be better practice
to define basename() conditionally on #ifndef HAVE_LIBGEN_H, after
adding the appropriate test to "configure".

Frederick



More information about the MPlayer-dev-eng mailing list