From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp16.mail.ru (smtp16.mail.ru [94.100.176.153]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id CC4684696C0 for ; Tue, 26 May 2020 17:42:42 +0300 (MSK) From: "Alexander V. Tikhonov" Date: Tue, 26 May 2020 17:42:33 +0300 Message-Id: <23557817ca293a7b00eebf0ac02422ec486409e6.1590503508.git.avtikhon@tarantool.org> In-Reply-To: References: In-Reply-To: References: Subject: [Tarantool-patches] [PATCH v2 2/7] build: fix static build w/ dockerfile with cmake List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Oleg Piskunov , Sergey Bronnikov Cc: tarantool-patches@dev.tarantool.org, Alexander Turenko Building the image got the issue: [ 1%] Performing configure step for 'bundled-libcurl-project' CMake Warning at CMakeLists.txt:50 (message): the curl cmake build system is poorly maintained. Be aware -- curl version=[7.66.0-DEV] -- Found c-ares: /tarantool/build/ares/dest/lib/libcares.a Found *nroff option: -- -man CMake Error at /usr/share/cmake/Modules/FindOpenSSL.cmake:278 (list): list GET given empty list Call Stack (most recent call first): CMakeLists.txt:347 (find_package) Root cause of the issue that Dockerfile uses globaly installed openSSL with: cmake ... -DOPENSSL_ROOT_DIR=/usr/local ... Its cmake build file: /usr/share/cmake/Modules/FindOpenSSL.cmake fails on parsing the SSL version: it has: REGEX "^#define[\t ]+OPENSSL_VERSION_NUMBER[\t ]+0x([0-9a-fA-F])+.*") but it should to use: REGEX "^#[\t ]*define[\t ]+OPENSSL_VERSION_NUMBER[\t ]+0x([0-9a-fA-F])+.*") Closes #5019 --- Dockerfile.staticbuild | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Dockerfile.staticbuild b/Dockerfile.staticbuild index f67f46f5e..01419dcc5 100644 --- a/Dockerfile.staticbuild +++ b/Dockerfile.staticbuild @@ -79,6 +79,7 @@ RUN set -x && \ RUN pip install -r /tarantool/test-run/requirements.txt +# cp FindOpenSSL.cmake /usr/share/cmake/Modules/FindOpenSSL.cmake && \ RUN set -x && \ cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo \ -DENABLE_DIST:BOOL=ON \ @@ -86,6 +87,8 @@ RUN set -x && \ -DOPENSSL_USE_STATIC_LIBS=ON \ -DOPENSSL_ROOT_DIR=/usr/local \ . && \ + sed 's%#define%#[\\t ]*define%g' -i \ + /usr/share/cmake/Modules/FindOpenSSL.cmake && \ make -j && make install ARG RUN_TESTS -- 2.17.1