[PATCH libXvMC 2/2] config: move wrapper in its own directory
Gaetan Nadon
memsize at videotron.ca
Mon Mar 7 08:08:58 PST 2011
This prevents the use of per-target compiler flags.
Makefiles are simpler.
The -D flags for the wrapper are moved with pre-precessor flags.
Signed-off-by: Gaetan Nadon <memsize at videotron.ca>
---
Makefile.am | 2 +-
configure.ac | 1 +
src/Makefile.am | 32 +++++++-------------------------
wrapper/Makefile.am | 22 ++++++++++++++++++++++
{src => wrapper}/XvMCWrapper.c | 0
5 files changed, 31 insertions(+), 26 deletions(-)
create mode 100644 wrapper/Makefile.am
rename {src => wrapper}/XvMCWrapper.c (100%)
diff --git a/Makefile.am b/Makefile.am
index a733b52..bc315df 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -19,7 +19,7 @@
# TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
# PERFORMANCE OF THIS SOFTWARE.
-SUBDIRS = src include
+SUBDIRS = src include wrapper
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = xvmc.pc
diff --git a/configure.ac b/configure.ac
index 05995fb..1434023 100644
--- a/configure.ac
+++ b/configure.ac
@@ -55,5 +55,6 @@ AC_CONFIG_FILES([Makefile
include/X11/Makefile
include/X11/extensions/Makefile
src/Makefile
+ wrapper/Makefile
xvmc.pc])
AC_OUTPUT
diff --git a/src/Makefile.am b/src/Makefile.am
index 741e7c5..05284fe 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,34 +1,16 @@
-lib_LTLIBRARIES = libXvMC.la libXvMCW.la
+lib_LTLIBRARIES = libXvMC.la
-libXvMC_la_SOURCES = \
- XvMC.c \
- XvMClibint.h
-
-libXvMCW_la_SOURCES = \
- XvMCWrapper.c
-
-AM_CFLAGS = $(CWARNFLAGS) @XVMC_CFLAGS@
-AM_CPPFLAGS = -I$(top_srcdir)/include @MALLOC_ZERO_CFLAGS@
-
-libXvMC_la_LIBADD = @XVMC_LIBS@
-libXvMC_la_CFLAGS = $(AM_CFLAGS)
-
-libXvMCW_la_LIBADD = @XVMC_LIBS@
-libXvMCW_la_CFLAGS = \
- $(AM_CFLAGS) \
- -DXVMC_CONFIGDIR=$(sysconfdir)/X11 \
- -DXVMC_SOVERSION=\".1.0\" \
- -DXV_SOVERSION=\".1.0\"
+AM_CPPFLAGS = -I$(top_srcdir)/include $(MALLOC_ZERO_CFLAGS)
+AM_CFLAGS = $(CWARNFLAGS) $(XVMC_CFLAGS)
+libXvMC_la_SOURCES = XvMC.c XvMClibint.h
+libXvMC_la_LIBADD = $(XVMC_LIBS)
libXvMC_la_LDFLAGS = -version-number 1:0:0 -no-undefined
-libXvMCW_la_LDFLAGS = -version-number 1:0:0 -no-undefined
-
if LINT
-ALL_LINT_FLAGS=$(LINT_FLAGS) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
+ALL_LINT_FLAGS=$(LINT_FLAGS) $(DEFS) $(DEFAULT_INCLUDES) \
$(AM_CPPFLAGS) $(CPPFLAGS)
lint:
- $(LINT) $(ALL_LINT_FLAGS) $(libXvMC_la_SOURCES) $(XVMC_LIBS)
- $(LINT) $(ALL_LINT_FLAGS) $(libXvMCW_la_CFLAGS) $(libXvMCW_la_SOURCES) $(XVMC_LIBS)
+ $(LINT) $(ALL_LINT_FLAGS) $(libXvMC_la_SOURCES) $(AM_CFLAGS) $(XVMC_LIBS)
endif LINT
diff --git a/wrapper/Makefile.am b/wrapper/Makefile.am
new file mode 100644
index 0000000..b3a1c21
--- /dev/null
+++ b/wrapper/Makefile.am
@@ -0,0 +1,22 @@
+lib_LTLIBRARIES = libXvMCW.la
+
+AM_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ $(MALLOC_ZERO_CFLAGS) \
+ -DXVMC_CONFIGDIR=$(sysconfdir)/X11 \
+ -DXVMC_SOVERSION=\".1.0\" \
+ -DXV_SOVERSION=\".1.0\"
+
+AM_CFLAGS = $(CWARNFLAGS) $(XVMC_CFLAGS)
+
+libXvMCW_la_SOURCES = XvMCWrapper.c
+libXvMCW_la_LIBADD = $(XVMC_LIBS)
+libXvMCW_la_LDFLAGS = -version-number 1:0:0 -no-undefined
+
+if LINT
+ALL_LINT_FLAGS=$(LINT_FLAGS) $(DEFS) $(DEFAULT_INCLUDES) \
+ $(AM_CPPFLAGS) $(CPPFLAGS)
+
+lint:
+ $(LINT) $(ALL_LINT_FLAGS) $(libXvMCW_la_SOURCES) $(AM_CFLAGS) $(XVMC_LIBS)
+endif LINT
diff --git a/src/XvMCWrapper.c b/wrapper/XvMCWrapper.c
similarity index 100%
rename from src/XvMCWrapper.c
rename to wrapper/XvMCWrapper.c
--
1.6.0.4
More information about the xorg-devel
mailing list