Skip to content

Commit

Permalink
Make OpenSSL 3.0.8 as default (open-eid#1081)
Browse files Browse the repository at this point in the history
IB-7377

Signed-off-by: Raul Metsma <[email protected]>
  • Loading branch information
metsma authored May 16, 2023
1 parent 7686eab commit 929a563
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 24 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -170,12 +170,12 @@ jobs:
uses: lukka/run-vcpkg@v7
with:
vcpkgArguments: openssl
vcpkgGitCommitId: a69b65229b3956b7f45abd81671b7330114bcaad
vcpkgGitCommitId: 9b9c2758ece1d8ac0de90589730bb5ccf45c0874
vcpkgTriplet: x64-windows
- name: Install Qt
uses: jurplel/install-qt-action@v3
uses: jurplel/install-qt-action@v2
with:
version: 6.4.3
version: 6.5.0
arch: win64_msvc2019_64
modules: qt5compat
- name: Setup dev env
Expand Down
8 changes: 4 additions & 4 deletions client/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,9 @@ if( APPLE )
COMMAND find $<TARGET_BUNDLE_CONTENT_DIR:${PROJECT_NAME}>/Frameworks -name Headers | xargs rm -rf
COMMAND install_name_tool -delete_rpath /Library/Frameworks $<TARGET_FILE:${PROJECT_NAME}>
COMMAND ln -sf digidocpp.framework/Libraries/libcrypto.dylib
$<TARGET_BUNDLE_CONTENT_DIR:${PROJECT_NAME}>/Frameworks/libcrypto.1.1.dylib
$<TARGET_BUNDLE_CONTENT_DIR:${PROJECT_NAME}>/Frameworks/libcrypto.3.dylib
COMMAND ln -sf digidocpp.framework/Libraries/libssl.dylib
$<TARGET_BUNDLE_CONTENT_DIR:${PROJECT_NAME}>/Frameworks/libssl.1.1.dylib
$<TARGET_BUNDLE_CONTENT_DIR:${PROJECT_NAME}>/Frameworks/libssl.3.dylib
)

add_custom_target(codesign DEPENDS ${PROJECT_NAME}
Expand Down Expand Up @@ -264,8 +264,8 @@ elseif(WIN32)
COMMAND ${CMAKE_COMMAND} -E copy AppxManifest.xml appx
COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:${PROJECT_NAME}> appx
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/qt.conf appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/libcrypto-1_1${OPENSSL_SUFFIX}.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/libssl-1_1${OPENSSL_SUFFIX}.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/libcrypto-3${OPENSSL_SUFFIX}.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/libssl-3${OPENSSL_SUFFIX}.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/zlib1.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/xerces-c_3_2.dll appx
COMMAND ${CMAKE_COMMAND} -E copy ${LIBS_PATH}/XalanMessages_1_12.dll appx
Expand Down
19 changes: 4 additions & 15 deletions prepare_osx_build_environment.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
set -e

######### Versions of libraries/frameworks to be compiled
QT_VER="6.4.2"
OPENSSL_VER="1.1.1t"
QT_VER="6.5.0"
OPENSSL_VER="3.0.8"
OPENLDAP_VER="2.6.4"
REBUILD=false
BUILD_PATH=~/cmake_builds
Expand Down Expand Up @@ -77,27 +77,16 @@ if [[ ! -d ${OPENSSL_PATH} ]] ; then
rm -rf openssl-${OPENSSL_VER}
tar xf openssl-${OPENSSL_VER}.tar.gz
cd openssl-${OPENSSL_VER}

sed -ie 's!, "apps"!!' Configure
sed -ie 's!, "fuzz"!!' Configure
sed -ie 's!, "test"!!' Configure
for ARCH in x86_64 arm64; do
case "${ARCH}" in
*x86_64*)
CC="" CFLAGS="" MACHINE=x86_64 KERNEL_BITS=64 ./config --prefix=${OPENSSL_PATH} shared no-hw no-engine no-tests enable-ec_nistp_64_gcc_128
;;
*arm64*)
CC="" CFLAGS="" MACHINE=arm64 KERNEL_BITS=64 ./config --prefix=${OPENSSL_PATH} shared no-hw no-engine no-tests enable-ec_nistp_64_gcc_128
;;
esac
./Configure darwin64-${ARCH} --prefix=${OPENSSL_PATH} shared no-autoload-config no-module no-engine no-tests enable-ec_nistp_64_gcc_128
make -s > /dev/null
make install_sw
mv ${OPENSSL_PATH} ${OPENSSL_PATH}.${ARCH}
make distclean
done
cp -a ${OPENSSL_PATH}.x86_64 ${OPENSSL_PATH}
cd ${OPENSSL_PATH}.arm64
for i in lib/lib*1.1.dylib; do
for i in lib/lib*3.dylib; do
lipo -create ${OPENSSL_PATH}.x86_64/${i} ${i} -output ${OPENSSL_PATH}/${i}
done
cd -
Expand Down
4 changes: 2 additions & 2 deletions qdigidoc4.wxs
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,8 @@ msiexec /a libdigidocpp-3.13.8.1378.msi /qn TARGETDIR=C:\target
<File Source="$(var.VCPATH)\msvcp140_2$(var.qt_suffix).dll"/>
<File Source="$(var.VCPATH)\vcruntime140_1$(var.qt_suffix).dll"/>
<?endif ?>
<File Source="$(var.libs_path)\libcrypto-1_1$(var.OpenSSLSuffix).dll"/>
<File Source="$(var.libs_path)\libssl-1_1$(var.OpenSSLSuffix).dll"/>
<File Source="$(var.libs_path)\libcrypto-3$(var.OpenSSLSuffix).dll"/>
<File Source="$(var.libs_path)\libssl-3$(var.OpenSSLSuffix).dll"/>
<File Source="$(var.qt_path)\Qt6Core$(var.qt_suffix).dll"/>
<File Source="$(var.qt_path)\Qt6Gui$(var.qt_suffix).dll"/>
<File Source="$(var.qt_path)\Qt6Network$(var.qt_suffix).dll"/>
Expand Down

0 comments on commit 929a563

Please sign in to comment.