From 776be07e39945e24a85a29546c581a2cbc7d3af8 Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 10:50:54 +0200 Subject: [PATCH 01/11] [202012] Test LGTM sai headers issue --- lgtm.yml | 1 + orchagent/main.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/lgtm.yml b/lgtm.yml index 17db711e35..3384d2d4f3 100644 --- a/lgtm.yml +++ b/lgtm.yml @@ -38,4 +38,5 @@ extraction: configure: command: - ./autogen.sh + - ls -al $LGTM_WORKSPACE/usr/include/sai || true ; ls -al /usr/include/sai || true - ./configure --prefix=/usr --with-extra-inc=$LGTM_WORKSPACE/usr/include --with-extra-lib=$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu diff --git a/orchagent/main.cpp b/orchagent/main.cpp index d71e4dab93..b7e64d8d1b 100644 --- a/orchagent/main.cpp +++ b/orchagent/main.cpp @@ -33,6 +33,7 @@ extern "C" { using namespace std; using namespace swss; + extern sai_switch_api_t *sai_switch_api; extern sai_router_interface_api_t *sai_router_intfs_api; From 3b49f93d2f537b1059e3768e9e87b038ecdd8f23 Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 10:53:47 +0200 Subject: [PATCH 02/11] add find --- lgtm.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/lgtm.yml b/lgtm.yml index 3384d2d4f3..b8d07354a4 100644 --- a/lgtm.yml +++ b/lgtm.yml @@ -39,4 +39,5 @@ extraction: command: - ./autogen.sh - ls -al $LGTM_WORKSPACE/usr/include/sai || true ; ls -al /usr/include/sai || true + - find / -name sai.h -ls - ./configure --prefix=/usr --with-extra-inc=$LGTM_WORKSPACE/usr/include --with-extra-lib=$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu From 40dfaf94e6313a2d3117de0a33a5e35524ee89be Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 11:14:30 +0200 Subject: [PATCH 03/11] update find --- lgtm.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lgtm.yml b/lgtm.yml index b8d07354a4..55e40b1252 100644 --- a/lgtm.yml +++ b/lgtm.yml @@ -39,5 +39,5 @@ extraction: command: - ./autogen.sh - ls -al $LGTM_WORKSPACE/usr/include/sai || true ; ls -al /usr/include/sai || true - - find / -name sai.h -ls + - find / -name sai.h -ls || true - ./configure --prefix=/usr --with-extra-inc=$LGTM_WORKSPACE/usr/include --with-extra-lib=$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu From 2649e0ab40b828f6b5c7a934aa2283443035fc31 Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 11:19:13 +0200 Subject: [PATCH 04/11] add verbose on dpkg --- lgtm.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lgtm.yml b/lgtm.yml index 55e40b1252..70dfe63557 100644 --- a/lgtm.yml +++ b/lgtm.yml @@ -29,12 +29,12 @@ extraction: - dpkg-deb -x libswsscommon_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -x libswsscommon-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - git clone --recursive https://github.com/Azure/sonic-sairedis; pushd sonic-sairedis; ./autogen.sh; DEB_BUILD_OPTIONS=nocheck SWSS_COMMON_INC="$LGTM_WORKSPACE/usr/include" SWSS_COMMON_LIB="$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu" fakeroot debian/rules binary-syncd-vs; popd - - dpkg-deb -x libsairedis_1.0.0_amd64.deb $LGTM_WORKSPACE - - dpkg-deb -x libsairedis-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - - dpkg-deb -x libsaimetadata_1.0.0_amd64.deb $LGTM_WORKSPACE - - dpkg-deb -x libsaimetadata-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - - dpkg-deb -x libsaivs_1.0.0_amd64.deb $LGTM_WORKSPACE - - dpkg-deb -x libsaivs-dev_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -vx libsairedis_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -vx libsairedis-dev_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -vx libsaimetadata_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -vx libsaimetadata-dev_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -vx libsaivs_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -vx libsaivs-dev_1.0.0_amd64.deb $LGTM_WORKSPACE configure: command: - ./autogen.sh From b5d5c82037e23212a76c3c7a3646f81ef2948ebb Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 14:48:47 +0200 Subject: [PATCH 05/11] add autoconf-archive --- lgtm.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/lgtm.yml b/lgtm.yml index 70dfe63557..88c8188d1d 100644 --- a/lgtm.yml +++ b/lgtm.yml @@ -24,6 +24,7 @@ extraction: - dh-exec - doxygen - graphviz + - autoconf-archive after_prepare: - git clone https://github.com/Azure/sonic-swss-common; pushd sonic-swss-common; ./autogen.sh; fakeroot dpkg-buildpackage -us -uc -b; popd - dpkg-deb -x libswsscommon_1.0.0_amd64.deb $LGTM_WORKSPACE From c4e4689cc74dddf3340c308a88867baa0a63d4bc Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 14:50:35 +0200 Subject: [PATCH 06/11] Compile sairedis and swss-common for 202012 branch --- lgtm.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lgtm.yml b/lgtm.yml index 88c8188d1d..8dff56c80e 100644 --- a/lgtm.yml +++ b/lgtm.yml @@ -26,10 +26,10 @@ extraction: - graphviz - autoconf-archive after_prepare: - - git clone https://github.com/Azure/sonic-swss-common; pushd sonic-swss-common; ./autogen.sh; fakeroot dpkg-buildpackage -us -uc -b; popd + - git clone https://github.com/Azure/sonic-swss-common; pushd sonic-swss-common; git checkout origin/202012; ./autogen.sh; fakeroot dpkg-buildpackage -us -uc -b; popd - dpkg-deb -x libswsscommon_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -x libswsscommon-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - - git clone --recursive https://github.com/Azure/sonic-sairedis; pushd sonic-sairedis; ./autogen.sh; DEB_BUILD_OPTIONS=nocheck SWSS_COMMON_INC="$LGTM_WORKSPACE/usr/include" SWSS_COMMON_LIB="$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu" fakeroot debian/rules binary-syncd-vs; popd + - git clone --recursive https://github.com/Azure/sonic-sairedis; pushd sonic-sairedis; git checkout origin/202012; ./autogen.sh; DEB_BUILD_OPTIONS=nocheck SWSS_COMMON_INC="$LGTM_WORKSPACE/usr/include" SWSS_COMMON_LIB="$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu" fakeroot debian/rules binary-syncd-vs; popd - dpkg-deb -vx libsairedis_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -vx libsairedis-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -vx libsaimetadata_1.0.0_amd64.deb $LGTM_WORKSPACE From 95601bbee70c00a950a40e7fb5269968cc0064f3 Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 15:02:06 +0200 Subject: [PATCH 07/11] checkout branch directly on lgtm --- lgtm.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lgtm.yml b/lgtm.yml index 8dff56c80e..6e593dec92 100644 --- a/lgtm.yml +++ b/lgtm.yml @@ -26,10 +26,10 @@ extraction: - graphviz - autoconf-archive after_prepare: - - git clone https://github.com/Azure/sonic-swss-common; pushd sonic-swss-common; git checkout origin/202012; ./autogen.sh; fakeroot dpkg-buildpackage -us -uc -b; popd + - git clone https://github.com/Azure/sonic-swss-common -b 202012 ; pushd sonic-swss-common; ./autogen.sh; fakeroot dpkg-buildpackage -us -uc -b; popd - dpkg-deb -x libswsscommon_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -x libswsscommon-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - - git clone --recursive https://github.com/Azure/sonic-sairedis; pushd sonic-sairedis; git checkout origin/202012; ./autogen.sh; DEB_BUILD_OPTIONS=nocheck SWSS_COMMON_INC="$LGTM_WORKSPACE/usr/include" SWSS_COMMON_LIB="$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu" fakeroot debian/rules binary-syncd-vs; popd + - git clone --recursive https://github.com/Azure/sonic-sairedis -b 202012 ; pushd sonic-sairedis; ./autogen.sh; DEB_BUILD_OPTIONS=nocheck SWSS_COMMON_INC="$LGTM_WORKSPACE/usr/include" SWSS_COMMON_LIB="$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu" fakeroot debian/rules binary-syncd-vs; popd - dpkg-deb -vx libsairedis_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -vx libsairedis-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -vx libsaimetadata_1.0.0_amd64.deb $LGTM_WORKSPACE From 210883fbfedfd0dd7fcc658ff614f31ed2627a70 Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 15:02:52 +0200 Subject: [PATCH 08/11] reorder branch on clone --- lgtm.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lgtm.yml b/lgtm.yml index 6e593dec92..ce56633eb9 100644 --- a/lgtm.yml +++ b/lgtm.yml @@ -26,10 +26,10 @@ extraction: - graphviz - autoconf-archive after_prepare: - - git clone https://github.com/Azure/sonic-swss-common -b 202012 ; pushd sonic-swss-common; ./autogen.sh; fakeroot dpkg-buildpackage -us -uc -b; popd + - git clone -b 202012 https://github.com/Azure/sonic-swss-common; pushd sonic-swss-common; ./autogen.sh; fakeroot dpkg-buildpackage -us -uc -b; popd - dpkg-deb -x libswsscommon_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -x libswsscommon-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - - git clone --recursive https://github.com/Azure/sonic-sairedis -b 202012 ; pushd sonic-sairedis; ./autogen.sh; DEB_BUILD_OPTIONS=nocheck SWSS_COMMON_INC="$LGTM_WORKSPACE/usr/include" SWSS_COMMON_LIB="$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu" fakeroot debian/rules binary-syncd-vs; popd + - git clone -b 202012 --recursive https://github.com/Azure/sonic-sairedis; pushd sonic-sairedis; ./autogen.sh; DEB_BUILD_OPTIONS=nocheck SWSS_COMMON_INC="$LGTM_WORKSPACE/usr/include" SWSS_COMMON_LIB="$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu" fakeroot debian/rules binary-syncd-vs; popd - dpkg-deb -vx libsairedis_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -vx libsairedis-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -vx libsaimetadata_1.0.0_amd64.deb $LGTM_WORKSPACE From e18451cbcd9e297a72c9eea2b1d6143ec137a7cd Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 16:01:16 +0200 Subject: [PATCH 09/11] Dummy --- orchagent/main.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/orchagent/main.cpp b/orchagent/main.cpp index b7e64d8d1b..0b09cdd54c 100644 --- a/orchagent/main.cpp +++ b/orchagent/main.cpp @@ -34,6 +34,7 @@ using namespace std; using namespace swss; + extern sai_switch_api_t *sai_switch_api; extern sai_router_interface_api_t *sai_router_intfs_api; From c370cdb7f55d2eded603d62d077c8eaa0addaca9 Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 17:07:14 +0200 Subject: [PATCH 10/11] Add lzmq to cfgmgr --- cfgmgr/Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cfgmgr/Makefile.am b/cfgmgr/Makefile.am index d9ba734d46..9393afb72e 100644 --- a/cfgmgr/Makefile.am +++ b/cfgmgr/Makefile.am @@ -2,7 +2,7 @@ INCLUDES = -I$(top_srcdir)/lib -I $(top_srcdir) -I $(top_srcdir)/orchagent -I $( CFLAGS_SAI = -I /usr/include/sai LIBNL_CFLAGS = -I/usr/include/libnl3 LIBNL_LIBS = -lnl-genl-3 -lnl-route-3 -lnl-3 -SAIMETA_LIBS = -lsaimeta -lsaimetadata +SAIMETA_LIBS = -lsaimeta -lsaimetadata -lzmq bin_PROGRAMS = vlanmgrd teammgrd portmgrd intfmgrd buffermgrd vrfmgrd nbrmgrd vxlanmgrd sflowmgrd natmgrd coppmgrd tunnelmgrd From 15b389dba9641fee780275acfd9cb2e8e2be155e Mon Sep 17 00:00:00 2001 From: kcudnik Date: Tue, 21 Sep 2021 19:54:32 +0200 Subject: [PATCH 11/11] Remove debug stuff --- lgtm.yml | 14 ++++++-------- orchagent/main.cpp | 2 -- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/lgtm.yml b/lgtm.yml index ce56633eb9..4f994273fe 100644 --- a/lgtm.yml +++ b/lgtm.yml @@ -30,15 +30,13 @@ extraction: - dpkg-deb -x libswsscommon_1.0.0_amd64.deb $LGTM_WORKSPACE - dpkg-deb -x libswsscommon-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - git clone -b 202012 --recursive https://github.com/Azure/sonic-sairedis; pushd sonic-sairedis; ./autogen.sh; DEB_BUILD_OPTIONS=nocheck SWSS_COMMON_INC="$LGTM_WORKSPACE/usr/include" SWSS_COMMON_LIB="$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu" fakeroot debian/rules binary-syncd-vs; popd - - dpkg-deb -vx libsairedis_1.0.0_amd64.deb $LGTM_WORKSPACE - - dpkg-deb -vx libsairedis-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - - dpkg-deb -vx libsaimetadata_1.0.0_amd64.deb $LGTM_WORKSPACE - - dpkg-deb -vx libsaimetadata-dev_1.0.0_amd64.deb $LGTM_WORKSPACE - - dpkg-deb -vx libsaivs_1.0.0_amd64.deb $LGTM_WORKSPACE - - dpkg-deb -vx libsaivs-dev_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -x libsairedis_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -x libsairedis-dev_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -x libsaimetadata_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -x libsaimetadata-dev_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -x libsaivs_1.0.0_amd64.deb $LGTM_WORKSPACE + - dpkg-deb -x libsaivs-dev_1.0.0_amd64.deb $LGTM_WORKSPACE configure: command: - ./autogen.sh - - ls -al $LGTM_WORKSPACE/usr/include/sai || true ; ls -al /usr/include/sai || true - - find / -name sai.h -ls || true - ./configure --prefix=/usr --with-extra-inc=$LGTM_WORKSPACE/usr/include --with-extra-lib=$LGTM_WORKSPACE/usr/lib/x86_64-linux-gnu diff --git a/orchagent/main.cpp b/orchagent/main.cpp index 0b09cdd54c..d71e4dab93 100644 --- a/orchagent/main.cpp +++ b/orchagent/main.cpp @@ -33,8 +33,6 @@ extern "C" { using namespace std; using namespace swss; - - extern sai_switch_api_t *sai_switch_api; extern sai_router_interface_api_t *sai_router_intfs_api;