Add support to build RMR/SI95 based binaries 10/2510/1
authorE. Scott Daniels <daniels@research.att.com>
Thu, 13 Feb 2020 16:06:41 +0000 (11:06 -0500)
committerE. Scott Daniels <daniels@research.att.com>
Thu, 13 Feb 2020 16:06:41 +0000 (11:06 -0500)
With the impending RMR switch to SI95 this change will build
both the old NNG and new SI95 based binaries for the listener
and test applications.

Container version bump to 1.3.2.

Signed-off-by: E. Scott Daniels <daniels@research.att.com>
Change-Id: I75a300c5100fa54b53622ca194b19417e5ef7b85

sidecars/listener/Dockerfile
sidecars/listener/Makefile
sidecars/listener/container-tag.yaml
sidecars/listener/verify.sh

index de8755b..b07aed5 100644 (file)
 #      Author:         E. Scott Daniels
 
 
-FROM nexus3.o-ran-sc.org:10004/bldr-ubuntu16-c-go:2-u16.04-nng as buildenv
+FROM nexus3.o-ran-sc.org:10004/bldr-ubuntu18-c-go:4-u18.04-nng as buildenv
 RUN mkdir /playpen
 
 RUN apt-get update && apt-get install -y cmake gcc make git g++ wget
 
 WORKDIR /playpen
 # Install RMr (runtime and dev) from debian package cached on packagecloud.io
-ARG RMR_VER=1.10.2
+ARG RMR_VER=3.1.2
 
 RUN wget -nv --content-disposition https://packagecloud.io/o-ran-sc/staging/packages/debian/stretch/rmr_${RMR_VER}_amd64.deb/download.deb
 RUN wget -nv --content-disposition https://packagecloud.io/o-ran-sc/staging/packages/debian/stretch/rmr-dev_${RMR_VER}_amd64.deb/download.deb
index 117c2bd..9c1bb8a 100644 (file)
@@ -20,9 +20,9 @@
 # this make file assuems that both NNG and RMR are installed and that the variables
 # LD_LIBRARY_PATH, LIBRARY_PATH are set correctly.
 
-binaries = mc_listener
+binaries = mc_listener mc_listener_si
 adjuncts = rdc_replay rdc_extract
-testers = sender pipe_reader
+testers = sender pipe_reader sender_si
 
 test_progs = sender unit_test pipe_reader
 lib_obj = mcl.o rdc.o
@@ -39,6 +39,9 @@ libmcl.a::    $(lib_obj) $(lib_h)
 mc_listener: mc_listener.c libmcl.a
        gcc mc_listener.c -o mc_listener -L. -lmcl  -lrmr_nng -lnng -lm -lpthread
 
+mc_listener_si: mc_listener.c libmcl.a
+       gcc mc_listener.c -o mc_listener_si -L. -lmcl  -lrmr_si -lm -lpthread
+
 
 # ---- testing stuff -----------------------------------------------------------------
 tests: $(test_progs)
@@ -46,6 +49,9 @@ tests: $(test_progs)
 sender : sender.c
        gcc sender.c -o sender  -lrmr_nng -lnng -lm -lpthread
 
+sender_si : sender.c
+       gcc sender.c -o sender_si  -lrmr_si -lm -lpthread
+
 pipe_reader : pipe_reader.c libmcl.a
        gcc pipe_reader.c -o pipe_reader  -L. -lmcl -lrmr_nng -lnng -lm -lpthread
 
@@ -67,3 +73,4 @@ clean:
 # remove anything that can be rebuilt
 nuke: clean
        rm -f *mcl.a $(binaries) $(test_progs)
+
index bc7fe28..aa27643 100644 (file)
@@ -1,4 +1,4 @@
 ---
-tag: '1.3.1'
+tag: '1.3.2'
 
 # this is used by CI jobs to apply a tag when it builds the image
index 7429336..b747904 100755 (executable)
@@ -57,7 +57,7 @@ function set_wait_values {
 #
 function run_sender {
        echo "starting sender"
-       RMR_SEED_RT=/tmp/local.rt RMR_RTG_SVC=9989 /playpen/bin/sender 43086 10000 >/tmp/sender.log 2>&1 &
+       RMR_SEED_RT=/tmp/local.rt RMR_RTG_SVC=9989 /playpen/${si}bin/sender 43086 10000 >/tmp/sender.log 2>&1 &
        spid=$!
        sleep $sender_wait
 
@@ -67,7 +67,7 @@ function run_sender {
 
 function run_listener {
        echo "starting listener"
-       /playpen/bin/mc_listener $ext_hdr -r 1 -d $fifo_dir >/tmp/listen.log 2>&1 &
+       /playpen/${si}bin/mc_listener $ext_hdr -r 1 -d $fifo_dir >/tmp/listen.log 2>&1 &
        lpid=$!
 
        sleep $listener_wait
@@ -104,6 +104,7 @@ endKat
 
 # ---- run everything ---------------------------------------------------
 
+si=""                                          # if -s given then we add this to sender/listener to run SI95 versions
 ext_hdr=""                                     # run with extended header enabled (-e turns extended off)
 long_test=0
 raw_capture=1
@@ -112,6 +113,7 @@ do
        case $1 in 
                -l)     long_test=1;;
                -n)     raw_capture=0;;
+               -s)     si="si_";;
                *)      echo "$1 is not a recognised option"
                        exit 1
                        ;;