diff --git a/ml_metadata/postgresql.BUILD b/ml_metadata/postgresql.BUILD index 2979d8195..93a38c3d3 100644 --- a/ml_metadata/postgresql.BUILD +++ b/ml_metadata/postgresql.BUILD @@ -127,12 +127,6 @@ cc_library( "//conditions:default": [ "-lcrypto", "-lssl", - "-lpthread", - "-lz", - "-lreadline", - "-lrt", - "-ldl", - "-lm", ], }), deps = [], @@ -483,10 +477,12 @@ genrule( "/* #undef HAVE_ATOMIC_H */", "", "/* Define to 1 if you have the `BIO_get_data' function. */", - "/* #undef HAVE_BIO_GET_DATA */", + # "/* #undef HAVE_BIO_GET_DATA */", + "#define HAVE_BIO_GET_DATA 1", "", "/* Define to 1 if you have the `BIO_meth_new' function. */", - "/* #undef HAVE_BIO_METH_NEW */", + # "/* #undef HAVE_BIO_METH_NEW */", + "#define HAVE_BIO_METH_NEW 1", "", "/* Define to 1 if you have the `cbrt' function. */", "#define HAVE_CBRT 1", @@ -513,8 +509,7 @@ genrule( "#define HAVE_CRYPT 1", "", "/* Define to 1 if you have the `CRYPTO_lock' function. */", - # "/* #undef HAVE_CRYPTO_LOCK */", - "#define HAVE_CRYPTO_LOCK 1", # for --with-openssl flag + "/* #undef HAVE_CRYPTO_LOCK */", "", "/* Define to 1 if you have the header file. */", "/* #undef HAVE_CRYPT_H */", @@ -729,8 +724,8 @@ genrule( "/* #undef HAVE_LDAP_INITIALIZE */", "", "/* Define to 1 if you have the `crypto' library (-lcrypto). */", - #"/* #undef HAVE_LIBCRYPTO */", - "#define HAVE_LIBCRYPTO 1", # for --with-openssl flag + # "/* #undef HAVE_LIBCRYPTO */", + "#define HAVE_LIBCRYPTO 1", "", "/* Define to 1 if you have the `ldap' library (-lldap). */", "/* #undef HAVE_LIBLDAP */", @@ -751,7 +746,8 @@ genrule( "/* #undef HAVE_LIBSELINUX */", "", "/* Define to 1 if you have the `ssl' library (-lssl). */", - "/* #undef HAVE_LIBSSL */", + # "/* #undef HAVE_LIBSSL */", + "#define HAVE_LIBSSL 1", "", "/* Define to 1 if you have the `wldap32' library (-lwldap32). */", "/* #undef HAVE_LIBWLDAP32 */", @@ -1120,8 +1116,7 @@ genrule( "/* #undef HAVE_WINLDAP_H */", "", "/* Define to 1 if you have the `X509_get_signature_nid' function. */", - # "/* #undef HAVE_X509_GET_SIGNATURE_NID */", - "#define HAVE_X509_GET_SIGNATURE_NID 1", # for --with-openssl flag + "/* #undef HAVE_X509_GET_SIGNATURE_NID */", "", "/* Define to 1 if the assembler supports X86_64's POPCNTQ instruction. */", "#define HAVE_X86_64_POPCNTQ 1", @@ -1196,7 +1191,7 @@ genrule( "#define PACKAGE_NAME \"PostgreSQL\"", "", "/* Define to the full name and version of this package. */", - "#define PACKAGE_STRING \"PostgreSQL 12.1\"", + "#define PACKAGE_STRING \"PostgreSQL 12.17\"", "", "/* Define to the one symbol short name of this package. */", "#define PACKAGE_TARNAME \"postgresql\"", @@ -1205,7 +1200,7 @@ genrule( "#define PACKAGE_URL \"\"", "", "/* Define to the version of this package. */", - "#define PACKAGE_VERSION \"12.1\"", + "#define PACKAGE_VERSION \"12.17\"", "", "/* Define to the name of a signed 128-bit integer type. */", "#define PG_INT128_TYPE __int128", @@ -1224,13 +1219,13 @@ genrule( "#define PG_PRINTF_ATTRIBUTE printf", "", "/* PostgreSQL version as a string */", - "#define PG_VERSION \"12.1\"", + "#define PG_VERSION \"12.17\"", "", "/* PostgreSQL version as a number */", "#define PG_VERSION_NUM 120001", "", "/* A string containing the version number, platform, and C compiler */", - "#define PG_VERSION_STR \"PostgreSQL 12.1 on x86_64-apple-darwin19.2.0, compiled by Apple clang version 11.0.0 (clang-1100.0.33.17), 64-bit\"", + "#define PG_VERSION_STR \"PostgreSQL 12.17 on x86_64-apple-darwin19.2.0, compiled by Apple clang version 11.0.0 (clang-1100.0.33.17), 64-bit\"", "", "/* Define to 1 to allow profiling output to be saved separately for each", " process. */", diff --git a/ml_metadata/tools/docker_build/build_manylinux.sh b/ml_metadata/tools/docker_build/build_manylinux.sh index 0fb17c459..894522fc3 100755 --- a/ml_metadata/tools/docker_build/build_manylinux.sh +++ b/ml_metadata/tools/docker_build/build_manylinux.sh @@ -49,6 +49,7 @@ function setup_environment() { # Auditwheel does not have a python2 version and auditwheel is just a binary. ${PIP_BIN} install auditwheel sudo ln -s ${PYTHON_BIN_PATH} /usr/bin/python3 + yum install openssl-devel -y } function build_wheel() { diff --git a/ml_metadata/tools/docker_server/Dockerfile b/ml_metadata/tools/docker_server/Dockerfile index 7fe00f28e..f8d5f32d9 100644 --- a/ml_metadata/tools/docker_server/Dockerfile +++ b/ml_metadata/tools/docker_server/Dockerfile @@ -33,7 +33,8 @@ RUN export DEBIAN_FRONTEND=noninteractive && \ git \ python3-distutils \ python-is-python3 \ - python3-dev + python3-dev \ + libssl-dev # Set up Bazel 5.3.0 ENV BAZEL_VERSION 5.3.0 diff --git a/ml_metadata/tools/docker_server/Dockerfile.fedora b/ml_metadata/tools/docker_server/Dockerfile.fedora index 98dc588a8..750e2fc25 100644 --- a/ml_metadata/tools/docker_server/Dockerfile.fedora +++ b/ml_metadata/tools/docker_server/Dockerfile.fedora @@ -15,7 +15,8 @@ RUN dnf update -y && \ unzip \ git \ python-is-python3 \ - python3-devel + python3-devel \ + openssl-devel # Set up Bazel 5.3.0 ENV BAZEL_VERSION 5.3.0 diff --git a/ml_metadata/tools/docker_server/Dockerfile.redhat b/ml_metadata/tools/docker_server/Dockerfile.redhat index e9f0b0dcc..db10ad4b1 100644 --- a/ml_metadata/tools/docker_server/Dockerfile.redhat +++ b/ml_metadata/tools/docker_server/Dockerfile.redhat @@ -15,8 +15,9 @@ RUN dnf update -y -q && \ unzip \ git \ findutils \ - python3 - + python3 \ + openssl-devel + # Set up Bazel 5.3.0 ENV BAZEL_VERSION 5.3.0 WORKDIR /