Skip to content

Commit

Permalink
test azure pipeline changes
Browse files Browse the repository at this point in the history
  • Loading branch information
qbdwlr committed Jul 8, 2021
1 parent 4e16eff commit 4a2617b
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 23 deletions.
26 changes: 21 additions & 5 deletions .azure-pipelines/build-template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ parameters:
- name: sonic_slave
type: string

- name: buildimage_artifact_name
type: string

- name: sairedis_artifact_name
type: string

Expand Down Expand Up @@ -54,10 +57,6 @@ jobs:
sudo apt-get install -y libzmq5 libzmq3-dev
sudo apt-get install -qq -y \
libhiredis-dev \
libnl-3-dev \
libnl-genl-3-dev \
libnl-route-3-dev \
libnl-nf-3-dev \
swig3.0
sudo apt-get install -y libdbus-1-3
sudo apt-get install -y libteam-dev \
Expand All @@ -82,7 +81,24 @@ jobs:
runVersion: 'latestFromBranch'
runBranch: 'refs/heads/master'
displayName: "Download sonic sairedis deb packages"
- task: DownloadPipelineArtifact@2
inputs:
source: specific
project: build
pipeline: 1
artifacts: sonic-buildimage.vs
runVersion: 'latestFromBranch'
runBranch: 'refs/heads/master'
displayName: "Download sonic buildimage deb packages"
- script: |
sudo dpkg -i ${{ parameters.buildimage_artifact_name }}/libnl-3-200_*.deb
sudo dpkg -i ${{ parameters.buildimage_artifact_name }}/libnl-3-dev_*.deb
sudo dpkg -i ${{ parameters.buildimage_artifact_name }}/libnl-genl-3-200_*.deb
sudo dpkg -i ${{ parameters.buildimage_artifact_name }}/libnl-genl-3-dev_*.deb
sudo dpkg -i ${{ parameters.buildimage_artifact_name }}/libnl-route-3-200_*.deb
sudo dpkg -i ${{ parameters.buildimage_artifact_name }}/libnl-route-3-dev_*.deb
sudo dpkg -i ${{ parameters.buildimage_artifact_name }}/libnl-nf-3-200_*.deb
sudo dpkg -i ${{ parameters.buildimage_artifact_name }}/libnl-nf-3-dev_*.deb
sudo dpkg -i ${{ parameters.swss_common_artifact_name }}/libswsscommon_1.0.0_${{ parameters.arch }}.deb
sudo dpkg -i ${{ parameters.swss_common_artifact_name }}/libswsscommon-dev_1.0.0_${{ parameters.arch }}.deb
sudo dpkg -i ${{ parameters.sairedis_artifact_name }}/libsaivs_*.deb
Expand All @@ -93,7 +109,7 @@ jobs:
sudo dpkg -i ${{ parameters.sairedis_artifact_name }}/libsaimetadata-dev_*.deb
sudo dpkg -i ${{ parameters.sairedis_artifact_name }}/syncd-vs_*.deb
workingDirectory: $(Pipeline.Workspace)
displayName: "Install sonic swss common and sairedis"
displayName: "Install libnl3, sonic swss common and sairedis"
- checkout: self
submodules: true
- script: |
Expand Down
13 changes: 0 additions & 13 deletions fpmsyncd/routesync.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1004,19 +1004,6 @@ bool RouteSync::getIfName(int if_index, char *if_name, size_t name_len)
return true;
}

#ifndef LIBNL3_ENCAP_MPLS
/* Thise stub is needed for sonic-swss Azure pipeline, since encap_mpls
* accessor is not yet upstreamed to external libnl3 project and sonic-swss
* uses released version of libnl3 rather than customized version available
* in sonic-buildimage.
*/
static
struct nl_addr *rtnl_route_nh_get_encap_mpls_dst(struct rtnl_nexthop *nh)
{
return NULL;
}
#endif // LIBNL3_ENCAP_MPLS

/*
* getNextHopList() - parses next hop list attached to route_obj
* @arg route_obj (input) Netlink route object
Expand Down
29 changes: 24 additions & 5 deletions lgtm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,39 @@ extraction:
- aspell
- aspell-en
- libhiredis-dev
- libnl-3-dev
- libnl-genl-3-dev
- libnl-route-3-dev
- libnl-nf-3-dev
- libzmq3-dev
- libzmq5
- swig3.0
- libpython2.7-dev
- libgtest-dev
- dh-exec
- doxygen
- cdbs
- bison
- flex
- graphviz
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-buildimage; pushd sonic-buildimage/src/libnl3
- git clone https://github.com/thom311/libnl libnl3-3.5.0; pushd libnl3-3.5.0; git checkout tags/libnl3_5_0
- git apply ../patch/0001-mpls-encap-accessors.patch
- git apply ../patch/0002-mpls-remove-nl_addr_valid.patch
- ln -s ../debian debian
- fakeroot dpkg-buildpackage -us -uc -b
- popd
- dpkg-deb -x libnl-3-200_3.5.0-1_amd64.deb $LGTM_WORKSPACE
- dpkg-deb -x libnl-3-dev_3.5.0-1_amd64.deb $LGTM_WORKSPACE
- dpkg-deb -x libnl-genl-3-200_3.5.0-1_amd64.deb $LGTM_WORKSPACE
- dpkg-deb -x libnl-genl-3-dev_3.5.0-1_amd64.deb $LGTM_WORKSPACE
- dpkg-deb -x libnl-route-3-200_3.5.0-1_amd64.deb $LGTM_WORKSPACE
- dpkg-deb -x libnl-route-3-dev_3.5.0-1_amd64.deb $LGTM_WORKSPACE
- dpkg-deb -x libnl-nf-3-200_3.5.0-1_amd64.deb $LGTM_WORKSPACE
- dpkg-deb -x libnl-nf-3-dev_3.5.0-1_amd64.deb $LGTM_WORKSPACE
- sudo dpkg -i libnl-3-dev_3.5.0-1_amd64.deb
- sudo dpkg -i libnl-genl-3-dev_3.5.0-1_amd64.deb
- sudo dpkg -i libnl-route-3-dev_3.5.0-1_amd64.deb
- sudo dpkg -i libnl-nf-3-dev_3.5.0-1_amd64.deb
- popd
- git clone https://github.com/qbdwlr/sonic-swss-common; pushd sonic-swss-common; git checkout azp; ./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
Expand Down

0 comments on commit 4a2617b

Please sign in to comment.