Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed python2 from build environment #159

Merged
merged 1 commit into from
Jun 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion dockerfiles/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ RUN apt-get install -y redis-server libhiredis0.14 python3-redis libc-ares2
RUN apt-get install -y \
make libtool m4 autoconf dh-exec debhelper automake cmake pkg-config \
libhiredis-dev libnl-3-dev libnl-genl-3-dev libnl-route-3-dev swig3.0 \
libpython2.7-dev libgtest-dev libgmock-dev libboost-dev autoconf-archive \
libgtest-dev libgmock-dev libboost-dev autoconf-archive \
uuid-dev libboost-serialization-dev libyang-dev libyang0.16

RUN apt-get install -y \
Expand All @@ -51,6 +51,7 @@ RUN git clone --recursive https://github.com/sonic-net/sonic-swss-common \
&& . /sai.env \
&& git checkout ${SWSS_COMMON_ID} \
&& ./autogen.sh \
&& export DEB_BUILD_PROFILES=nopython2 \
&& dpkg-buildpackage -us -uc -b --jobs=auto \
&& cd .. \
&& dpkg -i libswsscommon_1.0.0_amd64.deb \
Expand Down
2 changes: 1 addition & 1 deletion dockerfiles/Dockerfile.client
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ RUN git clone https://github.com/opencomputeproject/SAI.git \
&& make -j$(nproc) \
&& mkdir -p /etc/sai \
&& ./attr_list_generator > /etc/sai/sai.json.tmp \
&& python -mjson.tool /etc/sai/sai.json.tmp > /etc/sai/sai.json \
&& python3 -mjson.tool /etc/sai/sai.json.tmp > /etc/sai/sai.json \
&& rm /etc/sai/sai.json.tmp \
&& rm -rf /sai/SAI

Expand Down
3 changes: 2 additions & 1 deletion dockerfiles/Dockerfile.server
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ RUN apt-get install -y redis-server libhiredis0.14 python3-redis libc-ares2
RUN apt-get install -y \
make libtool m4 autoconf dh-exec debhelper automake cmake pkg-config \
libhiredis-dev libnl-3-dev libnl-genl-3-dev libnl-route-3-dev swig3.0 \
libpython2.7-dev libgtest-dev libgmock-dev libboost-dev autoconf-archive \
libgtest-dev libgmock-dev libboost-dev autoconf-archive \
uuid-dev libboost-serialization-dev libyang-dev libyang0.16

RUN apt-get install -y \
Expand All @@ -51,6 +51,7 @@ RUN git clone --recursive https://github.com/sonic-net/sonic-swss-common \
&& . /sai.env \
&& git checkout ${SWSS_COMMON_ID} \
&& ./autogen.sh \
&& export DEB_BUILD_PROFILES=nopython2 \
&& dpkg-buildpackage -us -uc -b --jobs=auto \
&& cd .. \
&& dpkg -i libswsscommon_1.0.0_amd64.deb \
Expand Down
4 changes: 3 additions & 1 deletion npu/broadcom/BCM56850/saivs/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ RUN git clone https://github.com/sonic-net/sonic-sairedis.git \
&& cd ../.. \
# Exclude sairedis tests that require Redis to be running
&& find . -type f -name Makefile.am | xargs sed -ri 's/^TESTS =/# TESTS =/' \
&& sed -i "s/^SUBDIRS = py2 py3/SUBDIRS = py3/" pyext/Makefile.am \
&& ./autogen.sh \
&& export DEB_BUILD_PROFILES=nopython2 \
&& dpkg-buildpackage -us -uc -b --target=binary-syncd-vs --jobs=auto \
&& cd .. \
&& dpkg -i libsaimetadata_1.0.0_amd64.deb \
Expand All @@ -45,7 +47,7 @@ RUN cd /sai/gen_attr_list \
&& make -j$(nproc) \
&& mkdir -p /etc/sai \
&& ./attr_list_generator > /etc/sai/sai.json.tmp \
&& python -mjson.tool /etc/sai/sai.json.tmp > /etc/sai/sai.json \
&& python3 -mjson.tool /etc/sai/sai.json.tmp > /etc/sai/sai.json \
&& rm /etc/sai/sai.json.tmp

# Setup supervisord
Expand Down
4 changes: 3 additions & 1 deletion npu/broadcom/BCM56850/saivs/Dockerfile.saithrift
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ RUN git clone https://github.com/sonic-net/sonic-sairedis.git \
&& cd .. \
# Exclude sairedis tests that require Redis to be running
&& find . -type f -name Makefile.am | xargs sed -ri 's/^TESTS =/# TESTS =/' \
&& sed -i "s/^SUBDIRS = py2 py3/SUBDIRS = py3/" pyext/Makefile.am \
&& ./autogen.sh \
&& export DEB_BUILD_PROFILES=nopython2 \
&& dpkg-buildpackage -us -uc -b --target=binary-syncd-vs --jobs=auto \
&& cd .. \
&& dpkg -i libsaimetadata_1.0.0_amd64.deb \
Expand All @@ -71,7 +73,7 @@ RUN cd /sai/gen_attr_list \
&& make -j$(nproc) \
&& mkdir -p /etc/sai \
&& ./attr_list_generator > /etc/sai/sai.json.tmp \
&& python -mjson.tool /etc/sai/sai.json.tmp > /etc/sai/sai.json \
&& python3 -mjson.tool /etc/sai/sai.json.tmp > /etc/sai/sai.json \
&& rm /etc/sai/sai.json.tmp

# Install PTF dependencies
Expand Down
2 changes: 2 additions & 0 deletions npu/broadcom/BCM56850/saivs/Dockerfile.server
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ RUN git clone https://github.com/sonic-net/sonic-sairedis.git \
&& cd .. \
# Exclude sairedis tests that require Redis to be running
&& find . -type f -name Makefile.am | xargs sed -ri 's/^TESTS =/# TESTS =/' \
&& sed -i "s/^SUBDIRS = py2 py3/SUBDIRS = py3/" pyext/Makefile.am \
&& ./autogen.sh \
&& export DEB_BUILD_PROFILES=nopython2 \
&& dpkg-buildpackage -us -uc -b --target=binary-syncd-vs --jobs=auto \
&& cd .. \
&& dpkg -i libsaimetadata_1.0.0_amd64.deb \
Expand Down
4 changes: 3 additions & 1 deletion phy/broadcom/BCM81724/saivs/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ RUN git clone https://github.com/sonic-net/sonic-sairedis.git \
&& cd ../.. \
# Exclude sairedis tests that require Redis to be running
&& find . -type f -name Makefile.am | xargs sed -ri 's/^TESTS =/# TESTS =/' \
&& sed -i "s/^SUBDIRS = py2 py3/SUBDIRS = py3/" pyext/Makefile.am \
&& ./autogen.sh \
&& export DEB_BUILD_PROFILES=nopython2 \
&& dpkg-buildpackage -us -uc -b --target=binary-syncd-vs --jobs=auto \
&& cd .. \
&& dpkg -i libsaimetadata_1.0.0_amd64.deb \
Expand All @@ -45,7 +47,7 @@ RUN cd /sai/gen_attr_list \
&& make -j$(nproc) \
&& mkdir -p /etc/sai \
&& ./attr_list_generator > /etc/sai/sai.json.tmp \
&& python -mjson.tool /etc/sai/sai.json.tmp > /etc/sai/sai.json \
&& python3 -mjson.tool /etc/sai/sai.json.tmp > /etc/sai/sai.json \
&& rm /etc/sai/sai.json.tmp

# Setup supervisord
Expand Down
4 changes: 3 additions & 1 deletion phy/broadcom/BCM81724/saivs/Dockerfile.saithrift
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ RUN git clone https://github.com/sonic-net/sonic-sairedis.git \
&& cd .. \
# Exclude sairedis tests that require Redis to be running
&& find . -type f -name Makefile.am | xargs sed -ri 's/^TESTS =/# TESTS =/' \
&& sed -i "s/^SUBDIRS = py2 py3/SUBDIRS = py3/" pyext/Makefile.am \
&& ./autogen.sh \
&& export DEB_BUILD_PROFILES=nopython2 \
&& dpkg-buildpackage -us -uc -b --target=binary-syncd-vs --jobs=auto \
&& cd .. \
&& dpkg -i libsaimetadata_1.0.0_amd64.deb \
Expand All @@ -71,7 +73,7 @@ RUN cd /sai/gen_attr_list \
&& make -j$(nproc) \
&& mkdir -p /etc/sai \
&& ./attr_list_generator > /etc/sai/sai.json.tmp \
&& python -mjson.tool /etc/sai/sai.json.tmp > /etc/sai/sai.json \
&& python3 -mjson.tool /etc/sai/sai.json.tmp > /etc/sai/sai.json \
&& rm /etc/sai/sai.json.tmp

# Install PTF dependencies
Expand Down
2 changes: 2 additions & 0 deletions phy/broadcom/BCM81724/saivs/Dockerfile.server
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ RUN git clone https://github.com/sonic-net/sonic-sairedis.git \
&& cd .. \
# Exclude sairedis tests that require Redis to be running
&& find . -type f -name Makefile.am | xargs sed -ri 's/^TESTS =/# TESTS =/' \
&& sed -i "s/^SUBDIRS = py2 py3/SUBDIRS = py3/" pyext/Makefile.am \
&& ./autogen.sh \
&& export DEB_BUILD_PROFILES=nopython2 \
&& dpkg-buildpackage -us -uc -b --target=binary-syncd-vs --jobs=auto \
&& cd .. \
&& dpkg -i libsaimetadata_1.0.0_amd64.deb \
Expand Down