OSDN Git Service

build: Change structure of the linker version script templates
authorDiego Biurrun <diego@biurrun.de>
Tue, 24 May 2016 00:18:40 +0000 (02:18 +0200)
committerDiego Biurrun <diego@biurrun.de>
Sun, 29 May 2016 14:43:11 +0000 (16:43 +0200)
Split version files into one line per symbol/directive to allow compatibility
with the Solaris linker without preprocessing and eliminate $ from version file
templates to simplify the postprocessing shell command.

Makefile
libavcodec/libavcodec.v
libavdevice/libavdevice.v
libavfilter/libavfilter.v
libavformat/libavformat.v
libavresample/libavresample.v
libavutil/libavutil.v
libswscale/libswscale.v

index 8e0cfce..d90d9be 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -63,9 +63,7 @@ COMPILE_HOSTC = $(call COMPILE,HOSTCC)
        $(Q)echo '#include "$*.h"' >$@
 
 %.ver: %.v
-       $(M)sed 's/$$MAJOR/$($(basename $(@F))_VERSION_MAJOR)/' $^ | sed -e 's/:/:\
-/' -e 's/; /;\
-/g' > $@
+       $(M)sed 's/MAJOR/$($(basename $(@F))_VERSION_MAJOR)/' $^ > $@
 
 %.c %.h %.ver: TAG = GEN
 
index bf14807..f1d5e5b 100644 (file)
@@ -1,4 +1,6 @@
-LIBAVCODEC_$MAJOR {
-        global: av*;
-        local:  *;
+LIBAVCODEC_MAJOR {
+    global:
+        av*;
+    local:
+        *;
 };
index 663af85..33042e5 100644 (file)
@@ -1,4 +1,6 @@
-LIBAVDEVICE_$MAJOR {
-        global: avdevice_*;
-        local: *;
+LIBAVDEVICE_MAJOR {
+    global:
+        avdevice_*;
+    local:
+        *;
 };
index 83e8887..6518e5f 100644 (file)
@@ -1,4 +1,7 @@
-LIBAVFILTER_$MAJOR {
-        global: avfilter_*; av_*;
-        local: *;
+LIBAVFILTER_MAJOR {
+    global:
+        avfilter_*;
+        av_*;
+    local:
+        *;
 };
index 6f11d60..47d5ddc 100644 (file)
@@ -1,4 +1,6 @@
-LIBAVFORMAT_$MAJOR {
-        global: av*;
-        local: *;
+LIBAVFORMAT_MAJOR {
+    global:
+        av*;
+    local:
+        *;
 };
index b8c7c7d..d6fc751 100644 (file)
@@ -1,4 +1,6 @@
-LIBAVRESAMPLE_$MAJOR {
-        global: av*;
-        local:  *;
+LIBAVRESAMPLE_MAJOR {
+    global:
+        av*;
+    local:
+        *;
 };
index e9f04cb..fb17058 100644 (file)
@@ -1,4 +1,6 @@
-LIBAVUTIL_$MAJOR {
-        global: av*;
-        local: *;
+LIBAVUTIL_MAJOR {
+    global:
+        av*;
+    local:
+        *;
 };
index 8b9a96a..96170a1 100644 (file)
@@ -1,4 +1,7 @@
-LIBSWSCALE_$MAJOR {
-        global: swscale_*; sws_*;
-        local: *;
+LIBSWSCALE_MAJOR {
+    global:
+        swscale_*;
+        sws_*;
+    local:
+        *;
 };