Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Les deux révisions précédentesRévision précédente
Prochaine révision
Révision précédente
doc:macosx [09/11/2023 21:14] – [MacOS Homebrew environment (old)] scorpio810doc:macosx [09/01/2024 16:01] (Version actuelle) – [Macports arm64 Apple silicon environments MAC Mini M2] scorpio810
Ligne 1: Ligne 1:
 ~~NOCACHE~~ ~~NOCACHE~~
-====== QElectroTech sous MacOSX ======+===== QElectroTech sous MacOSX =====
  
  
-====== Homebrew arm64 Apple silicon environments MAC Mini M2 ======+===== Macports arm64 Apple silicon environments MAC Mini M2 =====
  
 <code> <code>
-/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"+git clone https://invent.kde.org/graphics/digikam.git 
 +cd digikam/project/bundles/macports/
  
-brew install qt@5 
- 
-brew untap kde-mac/kde 2> /dev/null 
-brew tap kde-mac/kde https://invent.kde.org/packaging/homebrew-kde.git --force-auto-update 
-"$(brew --repo kde-mac/kde)/tools/do-caveats.sh" 
 </code> </code>
  
-<code> +<code=diff>diff --git a/project/bundles/3rdparty/ext_kf5/CMakeLists.txt b/project/bundles/3rdparty/ext_kf5/CMakeLists.txt 
-brew install kde-mac/kde/kf5-kwidgetsaddons +index 41a75f247f..04307322bd 100755 
-brew install kde-mac/kde/kf5-kcoreaddons+--- a/project/bundles/3rdparty/ext_kf5/CMakeLists.txt 
 ++++ b/project/bundles/3rdparty/ext_kf5/CMakeLists.txt 
 +@@ -107,7 +107,7 @@ function(InstallKDEComponent 
 +  
 +                             CONFIGURE_COMMAND cp ${CMAKE_CURRENT_SOURCE_DIR}/../../../../bootstrap.macports <SOURCE_DIR>/. && 
 +                                               sed -i '' -e "s/DBUILD_TESTING=ON/DBUILD_TESTING=OFF/g" <SOURCE_DIR>/bootstrap.macports && 
 +-                                              <SOURCE_DIR>/bootstrap.macports ${EXTPREFIX_frameworks} debug x86_64 "${argoptions}" 
 ++                                              <SOURCE_DIR>/bootstrap.macports ${EXTPREFIX_frameworks} debug arm64 "${argoptions}" 
 +  
 +                             BUILD_COMMAND cd <SOURCE_DIR>/build && $(MAKE) 
 +  
 +diff --git a/project/bundles/macports/01-build-macports.sh b/project/bundles/macports/01-build-macports.sh 
 +index 669ec675c1..82ac0ff093 100755 
 +--- a/project/bundles/macports/01-build-macports.sh 
 ++++ b/project/bundles/macports/01-build-macports.sh 
 +@@ -210,7 +210,7 @@ EOF 
 +         # No need to build with both architectures embeded (x86 and ARM) for Apple Silicon target 
 +  
 +         cat << EOF >> "$INSTALL_PREFIX/etc/macports/variants.conf" 
 +-+universal 
 ++++arm64 
 + EOF 
 +  
 +     fi 
 +@@ -275,25 +275,11 @@ port install 
 +              libpng \ 
 +              jpeg \ 
 +              tiff \ 
 +            boost \ 
 +-             eigen3 \ 
 +              gettext \ 
 +              libusb \ 
 +-             libgphoto2 \ 
 +-             jasper \ 
 +-             lcms2 \ 
 +-             expat \ 
 +              libxml2 \ 
 +              libxslt \ 
 +              libical \ 
 +-             lensfun \ 
 +-             bison \ 
 +-             py38-lxml \ 
 +-             x265 \ 
 +-             libde265 \ 
 +-             libheif \ 
 +-             aom \ 
 +-             ffmpeg \ 
 +              wget +ssl \ 
 +              qt5-qtbase \ 
 +              qt5-qtdeclarative \ 
 +@@ -305,22 +291,11 @@ port install \ 
 +              qt5-qttranslations \ 
 +              qt5-qtimageformats \ 
 +              qt5-qtnetworkauth \ 
 +-             qt5-sqlite-plugin \ 
 +-             qt5-mysql-plugin $MP_MARIADB_VARIANT 
 ++             qt5-sqlite-plugin 
 +  
 +-port deactivate boost 
 ++#port deactivate boost 
 +  
 +-if [[ $DK_QTWEBENGINE = 1 ]] ; then 
 +  
 +-    port install qt5-qtwebengine 
 +
 +-else 
 +
 +-    port install qt5-qtwebkit 
 +
 +-fi 
 +
 +-port activate boost 
 +  
 + # port broken since a while. check later 
 + #             sane-backends \ 
 +@@ -360,18 +335,7 @@ cmake $ORIG_WD/../3rdparty \ 
 +        -DKA_VERSION=$DK_KA_VERSION \ 
 +        -DKP_VERSION=$DK_KP_VERSION \ 
 +        -DKDE_VERSION=$DK_KDE_VERSION \ 
 +-       -DENABLE_QTVERSION=$DK_QTVERSION \ 
 +-       -DENABLE_QTWEBENGINE=$DK_QTWEBENGINE \ 
 +-       -Wno-dev 
 +
 +-if [[ $DK_QTWEBENGINE = 0 ]] ; then 
 +-    cmake --build . --config RelWithDebInfo --target ext_qtwebkit    -- -j$CPU_CORES 
 +-fi 
 +
 +-cmake --build . --config RelWithDebInfo --target ext_opencv      -- -j$CPU_CORES 
 +-cmake --build . --config RelWithDebInfo --target ext_imagemagick -- -j$CPU_CORES 
 +-cmake --build . --config RelWithDebInfo --target ext_libjxl      -- -j$CPU_CORES 
 +-cmake --build . --config RelWithDebInfo --target ext_libavif     -- -j$CPU_CORES 
 ++       -DENABLE_QTVERSION=$DK_QTVERSION 
 +  
 + ################################################################################################# 
 +  
 +diff --git a/project/bundles/macports/02-build-extralibs.sh b/project/bundles/macports/02-build-extralibs.sh 
 +index a94632c1a6..ca39301c7f 100755 
 +--- a/project/bundles/macports/02-build-extralibs.sh 
 ++++ b/project/bundles/macports/02-build-extralibs.sh 
 +@@ -68,16 +68,15 @@ cmake $ORIG_WD/../3rdparty \ 
 +        -DKA_VERSION=$DK_KA_VERSION \ 
 +        -DKP_VERSION=$DK_KP_VERSION \ 
 +        -DKDE_VERSION=$DK_KDE_VERSION \ 
 +-       -DENABLE_QTVERSION=$DK_QTVERSION \ 
 +-       -DENABLE_QTWEBENGINE=$DK_QTWEBENGINE \ 
 +-       -Wno-dev 
 ++       -DENABLE_QTVERSION=$DK_QTVERSION 
 +
 +  
 + # NOTE: The order to compile each component here is very important. 
 +  
 + # core KF5 frameworks dependencies 
 + cmake --build . --config RelWithDebInfo --target ext_extra-cmake-modules -- -j$CPU_CORES 
 + cmake --build . --config RelWithDebInfo --target ext_kconfig             -- -j$CPU_CORES 
 +-cmake --build . --config RelWithDebInfo --target ext_breeze-icons        -- -j$CPU_CORES 
 ++#cmake --build . --config RelWithDebInfo --target ext_breeze-icons        -- -j$CPU_CORES 
 + cmake --build . --config RelWithDebInfo --target ext_kcoreaddons         -- -j$CPU_CORES 
 + cmake --build . --config RelWithDebInfo --target ext_kwindowsystem       -- -j$CPU_CORES 
 + cmake --build . --config RelWithDebInfo --target ext_solid               -- -j$CPU_CORES 
 +@@ -106,10 +105,10 @@ cmake --build . --config RelWithDebInfo --target ext_kimageformats       -- -j$C 
 + #cmake --build . --config RelWithDebInfo --target ext_libksane            -- -j$CPU_CORES 
 +  
 + # Calendar support 
 +-cmake --build . --config RelWithDebInfo --target ext_kcalendarcore       -- -j$CPU_CORES 
 ++#cmake --build . --config RelWithDebInfo --target ext_kcalendarcore       -- -j$CPU_CORES 
 +  
 + # Breeze style support 
 +-cmake --build . --config RelWithDebInfo --target ext_breeze              -- -j$CPU_CORES 
 ++#cmake --build . --config RelWithDebInfo --target ext_breeze              -- -j$CPU_CORES 
 +  
 + ################################################################################################# 
 +  
 +diff --git a/project/bundles/macports/config.sh b/project/bundles/macports/config.sh 
 +index 37341eefb0..65c9e37442 100644 
 +--- a/project/bundles/macports/config.sh 
 ++++ b/project/bundles/macports/config.sh 
 +@@ -16,7 +16,7 @@ BUILDING_DIR="`pwd`/temp.build" 
 + ######################################################################## 
 +  
 + # Target macOS architecture: "x86_64" for Intel 64 bits, or "arm64" for Apple Silicon 64 bits. 
 +-ARCH_TARGET="x86_64" 
 ++ARCH_TARGET="arm64" 
 +  
 + if [[ $ARCH_TARGET = "x86_64" ]] ; then 
 +  
 +@@ -50,7 +50,7 @@ if [[ $ARCH_TARGET = "x86_64" ]] ; then 
 + elif [[ $ARCH_TARGET = "arm64" ]] ; then 
 +  
 +     # Apple Silicon is supported since macOS BigSur 
 +-    OSX_MIN_TARGET="11.0" 
 ++    OSX_MIN_TARGET="12.3" 
 +  
 + else 
 +  
 +@@ -128,7 +128,7 @@ DK_VERSION=master 
 + DK_DEBUG=0 
 +  
 + # Option to use QtWebEngine instead QtWebkit 
 +-DK_QTWEBENGINE=1 
 ++DK_QTWEBENGINE=0 
 +  
 + # Sign bundles with GPG. Passphrase must be hosted in ~/.gnupg/dkorg-gpg-pwd.txt 
 + DK_SIGN=0
 </code> </code>
  
-Copy your libs KF5 *.pri to your Qt brew install  +Add in your .bash_profile or in zsh profile [[https://support.apple.com/en-ca/HT208050|see]] 
-like+
 <code> <code>
-cp /opt/homebrew/Cellar/kf5-kcoreaddons/5.102.0/mkspecs/modules/qt_KCoreAddons.pri  /opt/homebrew/Cellar/qt@5/5.15.8_1/mkspecs/modules+PATH="/opt/digikam.org.arm64/libexec/qt5/bin:${PATH}" 
-cp /opt/homebrew/Cellar/kf5-kwidgetsaddons/5.102.0/include/KF5/KWidgetsAddons/qt_KWidgetsAddons.pri /opt/homebrew/Cellar/qt@5/5.15.8_1/mkspecs/modules/+PATH="/opt/digikam.org.arm64/bin:${PATH}" 
 +export PATH=/opt/digikam.org.arm64/libexec:$PATH 
 +export PATH=/opt/digikam.org.arm64/include:$PATH
 </code> </code>
  
- 
-cat /opt/homebrew/Cellar/qt@5/5.15.8_1/mkspecs/modules/qt_KCoreAddons.pri 
 <code> <code>
-QT.KCoreAddons.VERSION = 5.102.0+Copy your libs KF5 *.pri  /opt/digikam.org.arm64/mkspecs/modules/  to /opt/digikam.org.arm64/libexec/qt5/mkspecs/modules/ 
 +Edit your libs KF5 *.pri files in /opt/digikam.org.arm64/libexec/qt5/mkspecs/modules/ like this: 
 + 
 +QT.KCoreAddons.VERSION = 5.110.0
 QT.KCoreAddons.MAJOR_VERSION = 5 QT.KCoreAddons.MAJOR_VERSION = 5
-QT.KCoreAddons.MINOR_VERSION = 102+QT.KCoreAddons.MINOR_VERSION = 110
 QT.KCoreAddons.PATCH_VERSION = 0 QT.KCoreAddons.PATCH_VERSION = 0
 QT.KCoreAddons.name = KF5CoreAddons QT.KCoreAddons.name = KF5CoreAddons
 QT.KCoreAddons.module = KF5CoreAddons QT.KCoreAddons.module = KF5CoreAddons
 QT.KCoreAddons.defines =  QT.KCoreAddons.defines = 
-QT.KCoreAddons.includes =  /opt/homebrew/Cellar/kf5-kcoreaddons/5.102.0/include/KF5/KCoreAddons+QT.KCoreAddons.includes =  $$PWD/../../include/KF5/KCoreAddons
 QT.KCoreAddons.private_includes = QT.KCoreAddons.private_includes =
-QT.KCoreAddons.libs = /opt/homebrew/Cellar/kf5-kcoreaddons/5.102.0/lib+QT.KCoreAddons.libs = $$PWD/../../lib
 QT.KCoreAddons.depends = core QT.KCoreAddons.depends = core
 QT.KCoreAddons.module_config =  QT.KCoreAddons.module_config = 
-</code> 
-cat /opt/homebrew/Cellar/qt@5/5.15.8_1/mkspecs/modules/qt_KWidgetsAddons.pri 
-<code> 
-QT.KWidgetsAddons.VERSION = 5.102.0 
-QT.KWidgetsAddons.MAJOR_VERSION = 5 
-QT.KWidgetsAddons.MINOR_VERSION = 102 
-QT.KWidgetsAddons.PATCH_VERSION = 0 
-QT.KWidgetsAddons.name = KF5WidgetsAddons 
-QT.KWidgetsAddons.module = KF5WidgetsAddons 
-QT.KWidgetsAddons.defines =  
-QT.KWidgetsAddons.includes =  /opt/homebrew/Cellar/kf5-kwidgetsaddons/5.102.0/include/KF5/KWidgetsAddons 
-QT.KWidgetsAddons.private_includes = 
-QT.KWidgetsAddons.libs = /opt/homebrew/Cellar/kf5-kwidgetsaddons/5.102.0/lib 
-QT.KWidgetsAddons.depends = widgets 
-QT.KWidgetsAddons.module_config =  
-</code> 
  
 +To:
  
-<code> % cat .zshrc         
-export PATH="/opt/homebrew/opt/qt@5/bin:$PATH" 
-export LDFLAGS="-L/opt/homebrew/opt/qt@5/lib" 
-export CPPFLAGS="-I/opt/homebrew/opt/qt@5/include" 
-</code> 
  
-<code=diff> +QT.KCoreAddons.VERSION 5.110.0 
---- qelectrotech.pro +QT.KCoreAddons.MAJOR_VERSION 5 
-+++ qelectrotech.pro +QT.KCoreAddons.MINOR_VERSION 110 
-@@ -58,7 +58,7 @@ DEFINES +QET_ALLOW_OVERRIDE_CTBTD_OPTION +QT.KCoreAddons.PATCH_VERSION 0 
- DEFINES +QET_ALLOW_OVERRIDE_CD_OPTION +QT.KCoreAddons.name KF5CoreAddons 
-  +QT.KCoreAddons.module KF5CoreAddons 
- #comment the line below to disable the project database export +QT.KCoreAddons.defines =  
--DEFINES +QET_EXPORT_PROJECT_DB +QT.KCoreAddons.includes  /opt/digikam.org.arm64/include/KF5/KCoreAddons 
-+#DEFINES +QET_EXPORT_PROJECT_DB +QT.KCoreAddons.private_includes = 
-  +QT.KCoreAddons.libs = /opt/digikam.org.arm64/lib 
- # warn on *any* usage of deprecated APIs +QT.KCoreAddons.depends = core 
- #DEFINES +QT_DEPRECATED_WARNINGS +QT.KCoreAddons.module_config =  
-@@ -244,7 +244,7 @@ TARGET qelectrotech +
-  +
- # Ajustement des bibliotheques utilisees lors de l'edition des liens +
- unix:QMAKE_LIBS_THREAD --lpthread +
--unix|win32: PKGCONFIG += sqlite3 +
-+#unix|win32: PKGCONFIG += sqlite3 +
-  +
- # Enable C++17 +
- QMAKE_CXXFLAGS += -std=c++17 +
-@@ -312,7 +312,7 @@ macx { +
-         # les chemins definis precedemment sont relatifs au dossier contenant le binaire executable +
-         DEFINES += QET_LANG_PATH_RELATIVE_TO_BINARY_PATH +
-         DEFINES += QET_COMMON_COLLECTION_PATH_RELATIVE_TO_BINARY_PATH +
--        LIBS +=   /opt/digikam.org.x86_64/lib/libsqlite3.0.dylib +
-+         #LIBS +  /opt/digikam.org.x86_64/lib/libsqlite3.0.dylib +
- } +
-  +
- # Compilers-specific options+
 </code> </code>
 +  
 ===== MacOS Macports environment (new 2023) ===== ===== MacOS Macports environment (new 2023) =====
  
Imprimer/exporter