[MPlayer-dev-eng] [RFC] unify include paths in the build system
Diego Biurrun
diego at biurrun.de
Fri Jul 14 01:43:19 CEST 2006
Attached you will find one half of a patch that starts to unify the way
we handle include paths. Everything is put in EXTRA_INC instead of
littering the build system with many different FOO_INC variables.
The configure part is not completely done yet, as a next step we could
eliminate all the --with-fooincdir options. I'd appreciate if people
could test this in different environments, though. All compilation bugs
should already show themselves ;-)
Diego
-------------- next part --------------
Index: configure
===================================================================
--- configure (revision 19077)
+++ configure (working copy)
@@ -7410,7 +7410,10 @@
RANLIB = $_ranlib
INSTALL = $_install
# FIXME: Should only be $_inc_extra, time to get rid of all --with-fooincdir.
-EXTRA_INC = $_inc_extra $_inc_libdts $_inc_mlib
+EXTRA_INC = $_inc_extra $_inc_libdts $_inc_mlib $_inc_x11 $_inc_dxr2 $_inc_dvb \
+ $_inc_caca $_inc_arts $_inc_esd $_inc_polyp $_inc_jack $_inc_openal\
+ $_inc_sdl $_inc_xvid $_inc_x264 $_inc_directfb $_inc_cdparanoia \
+ $_inc_freetype $_inc_fontconfig $_inc_fribidi $_inc_libcdio $_inc_gtk
OPTFLAGS = -I../libvo -I../../libvo $_inc_x11 $CFLAGS \$(EXTRA_INC)
STRIPBINARIES = $_stripbinaries
CHARSET = $_charset
@@ -7464,7 +7467,6 @@
MATH_LIB = $_ld_lm
LIBC_LIB = $_ld_libC
-X11_INC = $_inc_x11
X11DIR = $_ld_x11
HAVE_XVMC_ACCEL = $_xvmc
@@ -7479,8 +7481,6 @@
X_LIB = $_ld_gl $_ld_dga $_ld_xv $_ld_xvmc $_ld_vm $_ld_xinerama $_ld_x11 $_ld_sock
GGI_LIB = $_ld_ggi
MLIB_LIB = $_ld_mlib
-DXR2_INC = $_inc_dxr2
-DVB_INC = $_inc_dvb
PNG_LIB = $_ld_png
JPEG_LIB = $_ld_jpeg
GIF_LIB = $_ld_gif
@@ -7488,7 +7488,6 @@
SVGA_LIB = $_ld_svga
VESA_LIB = $_ld_vesa
AA_LIB = $_ld_aa
-CACA_INC = $_inc_caca
CACA_LIB = $_ld_caca
# audio output
@@ -7500,15 +7499,10 @@
ALSA_LIB = $_ld_alsa
NAS_LIB = $_ld_nas
ARTS_LIB = $_ld_arts
-ARTS_INC = $_inc_arts
ESD_LIB = $_ld_esd
-ESD_INC = $_inc_esd
POLYP_LIB = $_ld_polyp
-POLYP_INC = $_inc_polyp
JACK_LIB = $_ld_jack
-JACK_INC = $_inc_jack
OPENAL_LIB = $_ld_openal
-OPENAL_INC = $_inc_openal
SGIAUDIO_LIB = $_ld_sgiaudio
# input/demuxer/codecs
@@ -7527,7 +7521,6 @@
DVDKIT2 = $_mpdvdkit
DVDNAV = $_dvdnav
DVDNAV_LIB = $_ld_dvdnav
-SDL_INC = $_inc_sdl
WIN32DLL = $_win32
W32_DEP = $_dep_win32
W32_LIB = $_ld_win32
@@ -7551,30 +7544,22 @@
ARCH_LIB = $_ld_arch $_ld_iconv
XVID = $_xvid
XVID4 = $_xvid4
-XVID_INC = $_inc_xvid
XVID_LIB = $_ld_xvid
X264 = $_x264
-X264_INC = $_inc_x264
X264_LIB = $_ld_x264
CONFIG_DTS = $_libdts
DTS_LIB = $_ld_libdts
DECORE_LIB = $_ld_decore $_ld_mp3lame
MENCODER = $_mencoder
ENCORE_LIB = $_ld_encore $_ld_mp3lame
-DIRECTFB_INC = $_inc_directfb
DIRECTFB_LIB = $_ld_directfb
CDDA = $_cdda
-CDPARANOIA_INC = $_inc_cdparanoia
CDPARANOIA_LIB = $_ld_cdparanoia
FREETYPE = $_freetype
-FREETYPE_INC = $_inc_freetype
FREETYPE_LIB = $_ld_freetype
-FONTCONFIG_INC = $_inc_fontconfig
FONTCONFIG_LIB = $_ld_fontconfig
CONFIG_ASS = $_ass
-FRIBIDI_INC = $_inc_fribidi
FRIBIDI_LIB = $_ld_fribidi
-LIBCDIO_INC = $_inc_libcdio
LIBCDIO_LIB = $_ld_libcdio
LIBLZO_LIB= $_ld_liblzo
LIBMAD = $_mad
@@ -7634,7 +7619,6 @@
TARGET_BUILTIN_3DNOW = $_mm3dnow
# --- GUI stuff ---
-GTK_INC = $_inc_gtk
GTKLIB = $_ld_gtk
GLIBLIB = $_ld_glib
GTK_LIBS = $_ld_static \$(GTKLIB) \$(GLIBLIB)
Index: Makefile
===================================================================
--- Makefile (revision 19078)
+++ Makefile (working copy)
@@ -121,18 +121,7 @@
$(FRIBIDI_LIB) \
$(ENCA_LIB) \
-CFLAGS = $(OPTFLAGS) -I. \
- $(CACA_INC) \
- $(CDPARANOIA_INC) \
- $(DVB_INC) \
- $(FONTCONFIG_INC) \
- $(FREETYPE_INC) \
- $(FRIBIDI_INC) \
- $(SDL_INC) \
- $(X11_INC) \
- $(XVID_INC) \
- $(LIBAV_INC) \
- $(LIBCDIO_INC) \
+CFLAGS = $(OPTFLAGS) -I. $(LIBAV_INC)
#CFLAGS += -Wall
Index: Gui/Makefile
===================================================================
--- Gui/Makefile (revision 19077)
+++ Gui/Makefile (working copy)
@@ -2,7 +2,7 @@
LIBNAME = libgui.a
-INCDIR = -I. -I.. -I../loader -I./wm -I./skin $(FREETYPE_INC) $(GTK_INC)
+INCDIR = -I. -I.. -I../loader -I./wm -I./skin
CFLAGS = $(OPTFLAGS) $(INCDIR) -DDEBUG
Index: libmpcodecs/Makefile
===================================================================
--- libmpcodecs/Makefile (revision 19077)
+++ libmpcodecs/Makefile (working copy)
@@ -331,8 +322,6 @@
-I../libmpdemux \
-I../loader \
$(LIBAV_INC) \
- $(X264_INC) \
- $(XVID_INC) \
-D_GNU_SOURCE \
.SUFFIXES: .c .o
Index: libao2/Makefile
===================================================================
--- libao2/Makefile (revision 19077)
+++ libao2/Makefile (working copy)
@@ -10,16 +10,7 @@
OBJS=$(SRCS:.c=.o)
-CFLAGS = $(OPTFLAGS) -I. -I.. \
- $(ARTS_INC) \
- $(DVB_INC) \
- $(DXR2_INC) \
- $(ESD_INC) \
- $(JACK_INC) \
- $(OPENAL_INC) \
- $(POLYP_INC) \
- $(SDL_INC) \
- $(X11_INC) \
+CFLAGS = $(OPTFLAGS) -I. -I..
.SUFFIXES: .c .o
Index: libvo/Makefile
===================================================================
--- libvo/Makefile (revision 19077)
+++ libvo/Makefile (working copy)
@@ -38,11 +38,6 @@
CFLAGS = $(OPTFLAGS) -I. -I.. -I../osdep \
$(LIBAV_INC) \
- $(FREETYPE_INC) \
- $(SDL_INC) \
- $(X11_INC) \
- $(DXR2_INC) \
- $(DIRECTFB_INC) \
-DMPG12PLAY \
#CFLAGS += -Wall
@@ -61,9 +56,6 @@
$(AR) r $(LIBNAME) $(OBJS)
$(RANLIB) $(LIBNAME)
-vo_mpegpes.o: vo_mpegpes.c
- $(CC) -c $(CFLAGS) $(DVB_INC) -o $@ $<
-
all: $(LIBNAME)
clean:
Index: libass/Makefile
===================================================================
--- libass/Makefile (revision 19077)
+++ libass/Makefile (working copy)
@@ -13,8 +13,6 @@
-I. -I.. \
-I../libmpcodecs \
-D_GNU_SOURCE \
- $(FREETYPE_INC) \
- $(FONTCONFIG_INC) \
.SUFFIXES: .c .o
Index: libmenu/Makefile
===================================================================
--- libmenu/Makefile (revision 19077)
+++ libmenu/Makefile (working copy)
@@ -15,11 +15,10 @@
ifeq ($(DVBIN),yes)
SRCS += menu_dvbin.c
-EXTRA_INC += $(DVB_INC)
endif
OBJS=$(SRCS:.c=.o)
-CFLAGS = $(OPTFLAGS) -I. -I.. -I../libmpcodecs $(FREETYPE_INC)
+CFLAGS = $(OPTFLAGS) -I. -I.. -I../libmpcodecs
.SUFFIXES: .c .o
Index: libmpdemux/Makefile
===================================================================
--- libmpdemux/Makefile (revision 19077)
+++ libmpdemux/Makefile (working copy)
@@ -207,7 +207,7 @@
OBJS = $(SRCS:.c=.o)
OBJS += $(CPLUSPLUSSRCS:.cpp=.o)
INCLUDE = -I.. -I../loader $(LIBAV_INC)
-CFLAGS = $(OPTFLAGS) $(INCLUDE) $(XMMS_CFLAGS) $(CDPARANOIA_INC) $(DVB_INC)
+CFLAGS = $(OPTFLAGS) $(INCLUDE) $(XMMS_CFLAGS)
CPLUSPLUSFLAGS = $(CFLAGS) $(CPLUSPLUSINCLUDE) -D__STDC_LIMIT_MACROS
CPLUSPLUS = $(CC)
More information about the MPlayer-dev-eng
mailing list