aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam Cozzette <acozzette@google.com>2018-07-06 12:38:14 -0700
committerFeng Xiao <xfxyjwf@gmail.com>2018-07-17 16:52:43 -0700
commit6fc2bac3f36e564e1c5e1171788ada13aff0d355 (patch)
tree80d78ed932c13e80b28fff7c55ad4bb18539fd3a
parentb3e4e3abe0d2f79ec9f1e4e24e12dc642d662546 (diff)
downloadprotobuf-6fc2bac3f36e564e1c5e1171788ada13aff0d355.tar.gz
protobuf-6fc2bac3f36e564e1c5e1171788ada13aff0d355.tar.bz2
protobuf-6fc2bac3f36e564e1c5e1171788ada13aff0d355.zip
Updated Docker setup to use GCC 4.8
Now that we depend on C++11, we need at least GCC 4.8 instead of 4.7. This change updates the Docker setup to continue using CentOS 6.6 but with GCC 4.8. I also added libm to the whitelist for dynamically linked libraries for the ARM64 protoc binary.
-rw-r--r--protoc-artifacts/Dockerfile15
-rwxr-xr-xprotoc-artifacts/build-protoc.sh2
-rwxr-xr-xprotoc-artifacts/scl-enable-devtoolset.sh2
3 files changed, 9 insertions, 10 deletions
diff --git a/protoc-artifacts/Dockerfile b/protoc-artifacts/Dockerfile
index c346586b..88936b26 100644
--- a/protoc-artifacts/Dockerfile
+++ b/protoc-artifacts/Dockerfile
@@ -28,15 +28,14 @@ RUN wget -q http://apache.cs.utah.edu/maven/maven-3/3.3.9/binaries/apache-maven-
tar xz -C /var/local
ENV PATH /var/local/apache-maven-3.3.9/bin:$PATH
-# Install GCC 4.7 to support -static-libstdc++
-RUN wget http://people.centos.org/tru/devtools-1.1/devtools-1.1.repo -P /etc/yum.repos.d && \
- bash -c 'echo "enabled=1" >> /etc/yum.repos.d/devtools-1.1.repo' && \
- bash -c "sed -e 's/\$basearch/i386/g' /etc/yum.repos.d/devtools-1.1.repo > /etc/yum.repos.d/devtools-i386-1.1.repo" && \
- sed -e 's/testing-/testing-i386-/g' -i /etc/yum.repos.d/devtools-i386-1.1.repo && \
+# Install GCC 4.8 to support -static-libstdc++
+RUN wget http://people.centos.org/tru/devtools-2/devtools-2.repo -P /etc/yum.repos.d && \
+ bash -c 'echo "enabled=1" >> /etc/yum.repos.d/devtools-2.repo' && \
+ bash -c "sed -e 's/\$basearch/i386/g' /etc/yum.repos.d/devtools-2.repo > /etc/yum.repos.d/devtools-i386-2.repo" && \
+ sed -e 's/testing-/testing-i386-/g' -i /etc/yum.repos.d/devtools-i386-2.repo && \
rpm --rebuilddb && \
- yum install -y devtoolset-1.1 \
- devtoolset-1.1-libstdc++-devel \
- devtoolset-1.1-libstdc++-devel.i686 && \
+ yum install -y devtoolset-2-gcc devtoolset-2-gcc-c++ devtoolset-2-binutils devtoolset-2-libstdc++-devel \
+ devtoolset-2-gcc.i686 devtoolset-2-gcc-c++.i686 devtoolset-2-binutils.i686 devtoolset-2-libstdc++-devel.i686 && \
yum clean all
COPY scl-enable-devtoolset.sh /var/local/
diff --git a/protoc-artifacts/build-protoc.sh b/protoc-artifacts/build-protoc.sh
index 7e1d4a89..b8d2eb87 100755
--- a/protoc-artifacts/build-protoc.sh
+++ b/protoc-artifacts/build-protoc.sh
@@ -150,7 +150,7 @@ checkDependencies ()
white_list="linux-vdso64\.so\.1\|libpthread\.so\.0\|libm\.so\.6\|libc\.so\.6\|libz\.so\.1\|ld64\.so\.2"
elif [[ "$ARCH" == aarch_64 ]]; then
dump_cmd='objdump -p '"$1"' | grep NEEDED'
- white_list="libpthread\.so\.0\|libc\.so\.6\|ld-linux-aarch64\.so\.1"
+ white_list="libpthread\.so\.0\|libm\.so\.6\|libc\.so\.6\|ld-linux-aarch64\.so\.1"
fi
elif [[ "$OS" == osx ]]; then
dump_cmd='otool -L '"$1"' | fgrep dylib'
diff --git a/protoc-artifacts/scl-enable-devtoolset.sh b/protoc-artifacts/scl-enable-devtoolset.sh
index 8d9585ea..30895585 100755
--- a/protoc-artifacts/scl-enable-devtoolset.sh
+++ b/protoc-artifacts/scl-enable-devtoolset.sh
@@ -10,4 +10,4 @@ quote() {
done
}
-exec scl enable devtoolset-1.1 "$(quote "$@")"
+exec scl enable devtoolset-2 "$(quote "$@")"