[vlc-commits] [Git][videolan/vlc][master] 8 commits: meson: treat link_args as valid vlc_modules key

Steve Lhomme (@robUx4) gitlab at videolan.org
Mon Jan 30 07:47:28 UTC 2023



Steve Lhomme pushed to branch master at VideoLAN / VLC


Commits:
c2e305c5 by Johannes Kauffmann at 2023-01-30T07:11:43+00:00
meson: treat link_args as valid vlc_modules key

This wasn't considered a valid entry, but doc/standalone/buildsystem.md
mentions it as a valid entry. The code below even checks for its value.

- - - - -
33fdb811 by Johannes Kauffmann at 2023-01-30T07:11:43+00:00
meson: check for -Wl,-Bsymbolic

- - - - -
fc4d8601 by Johannes Kauffmann at 2023-01-30T07:11:43+00:00
meson: avio: add symbolic_linkargs

- - - - -
f13a83c5 by Johannes Kauffmann at 2023-01-30T07:11:43+00:00
meson: swscale: add symbolic_linkargs

- - - - -
1c621746 by Johannes Kauffmann at 2023-01-30T07:11:43+00:00
meson: avcodec: add symbolic_linkargs

- - - - -
926855a4 by Johannes Kauffmann at 2023-01-30T07:11:43+00:00
meson: avformat: add symbolic_linkargs

- - - - -
1412fccf by Johannes Kauffmann at 2023-01-30T07:11:43+00:00
meson: x262: add symbolic_linkargs

- - - - -
26cabd5a by Johannes Kauffmann at 2023-01-30T07:11:43+00:00
meson: x264(10b): add symbolic_linkargs

- - - - -


6 changed files:

- meson.build
- modules/access/meson.build
- modules/codec/meson.build
- modules/demux/meson.build
- modules/meson.build
- modules/video_chroma/meson.build


Changes:

=====================================
meson.build
=====================================
@@ -791,6 +791,12 @@ add_project_arguments(
     cc.get_supported_arguments('-fvisibility=hidden'),
     language: ['c'])
 
+# Check if linker supports -Bsymbolic
+symbolic_linkargs = []
+if cc.has_link_argument('-Wl,-Bsymbolic')
+    symbolic_linkargs += '-Wl,-Bsymbolic'
+endif
+
 # Check for struct sockaddr_storage type
 # Define it to `sockaddr` if missing
 have_sockaddr_storage = cc.has_type('struct sockaddr_storage', prefix: '#include <sys/socket.h>')


=====================================
modules/access/meson.build
=====================================
@@ -401,7 +401,8 @@ if avformat_dep.found()
     vlc_modules += {
         'name' : 'avio',
         'sources' : files('avio.c'),
-        'dependencies' : [avutil_dep, avformat_dep, m_lib]
+        'dependencies' : [avutil_dep, avformat_dep, m_lib],
+        'link_args' : symbolic_linkargs
     }
 endif
 


=====================================
modules/codec/meson.build
=====================================
@@ -594,7 +594,8 @@ if avcodec_dep.found()
                 avcodec_extra_sources
         ),
         'dependencies' : [avutil_dep, avcodec_dep],
-        'link_with' : [libavcodec_common]
+        'link_with' : [libavcodec_common],
+        'link_args' : symbolic_linkargs
     }
 endif
 
@@ -681,7 +682,8 @@ if x262_dep.found()
         'name' : 'x262',
         'sources' : files('x264.c'),
         'dependencies' : [x262_dep],
-        'c_args' : ['-DPLUGIN_X262']
+        'c_args' : ['-DPLUGIN_X262'],
+        'link_args' : symbolic_linkargs
     }
 endif
 
@@ -692,7 +694,8 @@ if x26410b_dep.found()
         'name' : 'x26410b',
         'sources' : files('x264.c'),
         'dependencies' : [x26410b_dep],
-        'c_args' : ['-DPLUGIN_X264_10B']
+        'c_args' : ['-DPLUGIN_X264_10B'],
+        'link_args' : symbolic_linkargs
     }
 endif
 
@@ -703,7 +706,8 @@ if x264_dep.found()
         'name' : 'x264',
         'sources' : files('x264.c'),
         'dependencies' : [x264_dep],
-        'c_args' : ['-DPLUGIN_X264']
+        'c_args' : ['-DPLUGIN_X264'],
+        'link_args' : symbolic_linkargs
     }
 endif
 


=====================================
modules/demux/meson.build
=====================================
@@ -232,7 +232,8 @@ if avformat_dep.found()
             avformat_extra_sources
         ),
         'dependencies' : [avformat_dep, avutil_dep],
-        'link_with' : [libavcodec_common]
+        'link_with' : [libavcodec_common],
+        'link_args' : symbolic_linkargs
     }
 endif
 


=====================================
modules/meson.build
=====================================
@@ -260,6 +260,7 @@ foreach module : vlc_modules
         'name',
         'sources',
         'link_with',
+        'link_args',
         'link_depends',
         'link_language',
         'include_directories',


=====================================
modules/video_chroma/meson.build
=====================================
@@ -21,7 +21,8 @@ if swscale_dep.found()
         'swscale.c',
         '../codec/avcodec/chroma.c'
       ),
-      'dependencies' : [swscale_dep, m_lib]
+      'dependencies' : [swscale_dep, m_lib],
+      'link_args' : symbolic_linkargs
   }
 endif
 



View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/cf54537974963b208341f476d7ddca342afaaeaf...26cabd5a5f84df770452e0b267056c7fe5504e7e

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/cf54537974963b208341f476d7ddca342afaaeaf...26cabd5a5f84df770452e0b267056c7fe5504e7e
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list