[Mesa-dev] [PATCH 25/37] targets/vdpau: move linker flags to Automake.inc

Emil Velikov emil.l.velikov at gmail.com
Sat Nov 2 12:00:55 PDT 2013


Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
---
 src/gallium/Automake.inc                       |  7 +++++++
 src/gallium/targets/r300/vdpau/Makefile.am     | 10 +++-------
 src/gallium/targets/r600/vdpau/Makefile.am     | 10 +++-------
 src/gallium/targets/radeonsi/vdpau/Makefile.am | 10 +++-------
 src/gallium/targets/vdpau-nouveau/Makefile.am  |  7 +++----
 src/gallium/targets/vdpau-softpipe/Makefile.am |  7 +++----
 6 files changed, 22 insertions(+), 29 deletions(-)

diff --git a/src/gallium/Automake.inc b/src/gallium/Automake.inc
index b242bb4..765fdd2 100644
--- a/src/gallium/Automake.inc
+++ b/src/gallium/Automake.inc
@@ -36,3 +36,10 @@ GALLIUM_VIDEO_CFLAGS = \
 	$(PTHREAD_CFLAGS) \
 	$(LIBDRM_CFLAGS) \
 	$(VISIBILITY_CFLAGS)
+
+GALLIUM_VDPAU_LINKER_FLAGS = \
+	-module \
+	-version-number $(VDPAU_MAJOR):$(VDPAU_MINOR) \
+	-export-symbols-regex $(VDPAU_EXPORTS) \
+	-shared \
+	-no-undefined
diff --git a/src/gallium/targets/r300/vdpau/Makefile.am b/src/gallium/targets/r300/vdpau/Makefile.am
index 9bc19d7..b597405 100644
--- a/src/gallium/targets/r300/vdpau/Makefile.am
+++ b/src/gallium/targets/r300/vdpau/Makefile.am
@@ -20,6 +20,8 @@
 # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 # DEALINGS IN THE SOFTWARE.
 
+# Note: Make sure VDPAU_EXPORTS is defined before including Automake.inc
+VDPAU_EXPORTS = '^(vdp_imp_device_create_x11|radeon_drm_winsys_create)$$'
 include $(top_srcdir)/src/gallium/Automake.inc
 
 AM_CFLAGS = \
@@ -28,19 +30,13 @@ AM_CFLAGS = \
 vdpaudir = $(VDPAU_LIB_INSTALL_DIR)
 vdpau_LTLIBRARIES = libvdpau_r300.la
 
-EXPORTS = '^(vdp_imp_device_create_x11|radeon_drm_winsys_create)$$'
-
 nodist_EXTRA_libvdpau_r300_la_SOURCES = dummy.cpp
 libvdpau_r300_la_SOURCES = \
 	drm_target.c \
 	vl_winsys_dri.c
 
 libvdpau_r300_la_LDFLAGS = \
-	-module \
-	-version-number $(VDPAU_MAJOR):$(VDPAU_MINOR) \
-	-export-symbols-regex $(EXPORTS) \
-	-shared \
-	-no-undefined
+	$(GALLIUM_VDPAU_LINKER_FLAGS)
 
 libvdpau_r300_la_LIBADD = \
 	$(top_builddir)/src/gallium/auxiliary/libgallium.la \
diff --git a/src/gallium/targets/r600/vdpau/Makefile.am b/src/gallium/targets/r600/vdpau/Makefile.am
index 8da78e8..15d68b7 100644
--- a/src/gallium/targets/r600/vdpau/Makefile.am
+++ b/src/gallium/targets/r600/vdpau/Makefile.am
@@ -20,6 +20,8 @@
 # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 # DEALINGS IN THE SOFTWARE.
 
+# Note: Make sure VDPAU_EXPORTS is defined before including Automake.inc
+VDPAU_EXPORTS = '^(vdp_imp_device_create_x11|radeon_drm_winsys_create)$$'
 include $(top_srcdir)/src/gallium/Automake.inc
 
 AM_CFLAGS = \
@@ -28,18 +30,12 @@ AM_CFLAGS = \
 vdpaudir = $(VDPAU_LIB_INSTALL_DIR)
 vdpau_LTLIBRARIES = libvdpau_r600.la
 
-EXPORTS = '^(vdp_imp_device_create_x11|radeon_drm_winsys_create)$$'
-
 libvdpau_r600_la_SOURCES = \
 	drm_target.c \
 	vl_winsys_dri.c
 
 libvdpau_r600_la_LDFLAGS = \
-	-module \
-	-version-number $(VDPAU_MAJOR):$(VDPAU_MINOR) \
-	-export-symbols-regex $(EXPORTS) \
-	-shared \
-	-no-undefined
+	$(GALLIUM_VDPAU_LINKER_FLAGS)
 
 libvdpau_r600_la_LIBADD = \
 	$(top_builddir)/src/gallium/auxiliary/libgallium.la \
diff --git a/src/gallium/targets/radeonsi/vdpau/Makefile.am b/src/gallium/targets/radeonsi/vdpau/Makefile.am
index 8dd7dc4..7f0f808 100644
--- a/src/gallium/targets/radeonsi/vdpau/Makefile.am
+++ b/src/gallium/targets/radeonsi/vdpau/Makefile.am
@@ -20,6 +20,8 @@
 # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 # DEALINGS IN THE SOFTWARE.
 
+# Note: Make sure VDPAU_EXPORTS is defined before including Automake.inc
+VDPAU_EXPORTS = '^(vdp_imp_device_create_x11|radeon_drm_winsys_create)$$'
 include $(top_srcdir)/src/gallium/Automake.inc
 
 AM_CFLAGS = \
@@ -28,19 +30,13 @@ AM_CFLAGS = \
 vdpaudir = $(VDPAU_LIB_INSTALL_DIR)
 vdpau_LTLIBRARIES = libvdpau_radeonsi.la
 
-EXPORTS = '^(vdp_imp_device_create_x11|radeon_drm_winsys_create)$$'
-
 nodist_EXTRA_libvdpau_radeonsi_la_SOURCES = dummy.cpp
 libvdpau_radeonsi_la_SOURCES = \
 	drm_target.c \
 	vl_winsys_dri.c
 
 libvdpau_radeonsi_la_LDFLAGS = \
-	-module \
-	-version-number $(VDPAU_MAJOR):$(VDPAU_MINOR) \
-	-export-symbols-regex $(EXPORTS) \
-	-shared \
-	-no-undefined
+	$(GALLIUM_VDPAU_LINKER_FLAGS)
 
 libvdpau_radeonsi_la_LIBADD = \
 	$(top_builddir)/src/gallium/auxiliary/libgallium.la \
diff --git a/src/gallium/targets/vdpau-nouveau/Makefile.am b/src/gallium/targets/vdpau-nouveau/Makefile.am
index e23d160..46d849c 100644
--- a/src/gallium/targets/vdpau-nouveau/Makefile.am
+++ b/src/gallium/targets/vdpau-nouveau/Makefile.am
@@ -20,6 +20,8 @@
 # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 # DEALINGS IN THE SOFTWARE.
 
+# Note: Make sure VDPAU_EXPORTS is defined before including Automake.inc
+VDPAU_EXPORTS = '^(vdp_imp_device_create_x11|nouveau_drm_screen_create)$$'
 include $(top_srcdir)/src/gallium/Automake.inc
 
 AM_CFLAGS = \
@@ -34,10 +36,7 @@ libvdpau_nouveau_la_SOURCES = \
 	vl_winsys_dri.c
 
 libvdpau_nouveau_la_LDFLAGS = \
-	-module \
-	-version-number $(VDPAU_MAJOR):$(VDPAU_MINOR) \
-	-shared \
-	-no-undefined
+	$(GALLIUM_VDPAU_LINKER_FLAGS)
 
 libvdpau_nouveau_la_LIBADD = \
 	$(top_builddir)/src/gallium/auxiliary/libgallium.la \
diff --git a/src/gallium/targets/vdpau-softpipe/Makefile.am b/src/gallium/targets/vdpau-softpipe/Makefile.am
index 20f001b..ab45b64 100644
--- a/src/gallium/targets/vdpau-softpipe/Makefile.am
+++ b/src/gallium/targets/vdpau-softpipe/Makefile.am
@@ -20,6 +20,8 @@
 # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
 # DEALINGS IN THE SOFTWARE.
 
+# Note: Make sure VDPAU_EXPORTS is defined before including Automake.inc
+VDPAU_EXPORTS = '^(vdp_imp_device_create_x11|xlib_create_sw_winsys)$$'
 include $(top_srcdir)/src/gallium/Automake.inc
 
 AM_CFLAGS = \
@@ -34,10 +36,7 @@ libvdpau_softpipe_la_SOURCES = \
 	vl_winsys_xsp.c
 
 libvdpau_softpipe_la_LDFLAGS = \
-	-module \
-	-version-number $(VDPAU_MAJOR):$(VDPAU_MINOR) \
-	-shared \
-	-no-undefined
+	$(GALLIUM_VDPAU_LINKER_FLAGS)
 
 libvdpau_softpipe_la_LIBADD = \
 	$(top_builddir)/src/gallium/auxiliary/libgallium.la \
-- 
1.8.4.2



More information about the mesa-dev mailing list