]> git.lyx.org Git - lyx.git/blobdiff - INSTALL.cmake
Do not compute metrics at each preview when loading file
[lyx.git] / INSTALL.cmake
index 731fbc5447e2d952170c16c3f3267f215b0e86ce..83f892c4706d6370a09c4247dd65e90596f5e968 100644 (file)
@@ -2,38 +2,40 @@
 Building LyX with CMake
 =========================
 
-    Install CMake from www.cmake.org or your distribution (version >= 2.6.4).
+    Install CMake from www.cmake.org or your distribution (version >= 3.1.0).
 
 
 
 3rd party libraries
 --------------------
 
-    Install Qt 4 or Qt 5 and make sure qmake is found.
+    Install Qt 5 or Qt 6 and make sure qmake is found.
         Add the folder with qmake to the environment variable PATH.
         If you've compiled Qt by yourself or qmake is not found after
         installing Qt fix PATH,
         Linux/Unix: export PATH=<your path to qt>/bin:$PATH
         Windows   : set PATH=<your path to qt>\bin;%PATH%
-        If you use Qt 5, use -DLYX_USE_QT=QT5, otherwise Qt 4 will be searched.
+        if you use -DLYX_USE_QT=AUTO, or do not use LYX_USE_QT, Qt 6 will be searched first
+        and if not found Qt 5 will be used.
+        If you want to use Qt 5, use -DLYX_USE_QT=QT5.
 
     When you want to run LyX without installing from an out-of-source
-    build directory you have to set the environment variable LYX_DIR_21x
+    build directory you have to set the environment variable LYX_DIR_24x
     and it must point to the lib dir in the source tree.
-        Linux/Unix: export LYX_DIR_21x=<lyx-source>/lib
-        Windows   : set LYX_DIR_21x=<lyx-source>\lib
+        Linux/Unix: export LYX_DIR_24x=<lyx-source>/lib
+        Windows   : set LYX_DIR_24x=<lyx-source>\lib
 
     Windows specific
 
         On Windows install the supplementary modules:
-        * Visual Studio 2010: ftp://ftp.lyx.org/pub/lyx/devel/win_deps/lyx20-deps-msvc2010.zip
+        * Visual Studio 2015: ftp://ftp.lyx.org/pub/lyx/devel/win_deps/lyx-windows-deps-msvc2015.zip
                 or use the option LYX_DEPENDENCIES_DOWNLOAD, then you have to add
                 these paths to your PATH variable:
-                  <build-dir>\msvc2010-deps\deps20\bin
-                  <build-dir>\msvc2010-deps\deps20\python
-                  <build-dir>\msvc2010-deps\deps20\imagemagick
-                  <build-dir>\msvc2010-deps\deps20\ghostscript
-                  <build-dir>\msvc2010-deps\deps20\gettext-tools
+                  <build-dir>\lyx-windows-deps-msvc2015\bin
+                  <build-dir>\lyx-windows-deps-msvc2015\Python
+                  <build-dir>\lyx-windows-deps-msvc2015\imagemagick
+                  <build-dir>\lyx-windows-deps-msvc2015\ghostscript
+                  <build-dir>\lyx-windows-deps-msvc2015\gettext-tools
 
         If cmake couldn't find these modules set GNUWIN32_DIR, e.g.
         -DGNUWIN32_DIR=c:\gnuwin32. By default cmake searches in your 
@@ -132,26 +134,45 @@ Build options
 
     Options could be passed by the -D prefix when running cmake.
     Available options will be listed on each cmake run.
-    -Dhelp=1 lists all available options:
+    "cmake -Dhelp=1 -S <lyx-source-dir> -B /tmp" lists all available options:
+    !!! Mark, that using this command creates CMakeCache.txt and CMakeFiles
+    !!! which have to be removed afterwards. Therefore it is better to explicitly
+    !!! specify a temporary build directory (/tmp in this example)
+    
 
     # Available on all systems/compilers
     -- LYX_CPACK                = OFF    : Use the CPack management (Implies LYX_INSTALL option)
+    -- LYX_LOCALVERSIONING      = ON     : Add version info to created package name (only used if LYX_CPACK option set)
     -- LYX_INSTALL              = OFF    : Build install projects/rules (implies a bunch of other options)
     -- LYX_NLS                  = ON     : Use nls
+    -- LYX_REQUIRE_SPELLCHECK   = OFF    : Abort if no spellchecker available
     -- LYX_ASPELL               = OFF    : Require aspell
     -- LYX_ENCHANT              = OFF    : Require Enchant
     -- LYX_HUNSPELL             = OFF    : Require Hunspell
-    -- LYX_DEVEL_VERSION        = OFF    : Build developer version
     -- LYX_RELEASE              = OFF    : Build release version, build debug when disabled
+    -- LYX_DEBUG                = ON     : Enforce debug build
+    -- LYX_NO_OPTIMIZE          = OFF    : Don't use any optimization/debug flags
     -- LYX_PACKAGE_SUFFIX       = ON     : Use version suffix for packaging
     -- LYX_PCH                  = OFF    : Use precompiled headers
     -- LYX_MERGE_FILES          = OFF    : Merge source files into one compilation unit
     -- LYX_MERGE_REBUILD        = OFF    : Rebuild generated files from merged files build
     -- LYX_QUIET                = OFF    : Don't generate verbose makefiles
     -- LYX_INSTALL_PREFIX       = OFF    : Install path for LyX
+    -- LYX_BUNDLE               = OFF    : Build bundle  (experimental) 
+    -- LYX_ENABLE_URLTESTS      = OFF    : Enable for URL tests
+    -- LYX_ENABLE_EXPORT_TESTS  = ON     : Enable for export tests
+    -- LYX_ENABLE_KEYTESTS      = ON     : Enable for keytests
+    -- LYX_ASAN                 = OFF    : Use address sanitizer
+    -- LYX_USE_FILEDIALOG       = NATI   : Use native or QT file dialog (QT NATIVE)
+    -- LYX_USE_QT               = QT6    : Use Qt version as frontend (AUTO QT5 QT6)
+    -- LYX_DISABLE_CALLSTACK_PRI= OFF    : do not print a callstack when crashing
+    -- LYX_EXTERNAL_Z           = ON     : OFF := Build 3rdparty lib zlib
+    -- LYX_EXTERNAL_ICONV       = ON     : OFF := Build 3rdparty lib iconvlib
+    -- LYX_EXTERNAL_HUNSPELL    = OFF    : OFF := Build 3rdparty lib hunspelllib
+    -- LYX_EXTERNAL_MYTHES      = OFF    : OFF := Build 3rdparty lib mytheslib (AUTO OFF ON)
 
     # GCC specific 
-    -- LYX_PROFILE              = OFF    : Build profile version
+    -- LYX_PROFILE              = OFF    : Build with options for gprof
     -- LYX_EXTERNAL_BOOST       = OFF    : Use external boost
     -- LYX_PROGRAM_SUFFIX       = ON     : Append version suffix to binaries
     -- LYX_DEBUG_GLIBC          = OFF    : Enable libstdc++ debug mode
@@ -162,12 +183,14 @@ Build options
     -- LYX_CONSOLE              = ON     : Show console on Windows
     -- LYX_VLD                  = OFF    : Use VLD with MSVC
     -- LYX_WALL                 = OFF    : Enable all warnings
-    -- LYX_CONFIGURE_CHECKS     = OFF    : Also run configure checks for MSVC
     -- LYX_DEPENDENCIES_DOWNLOAD= OFF    : Download precompiled 3rd party libraries for MSVC 10
 
+    # APPLE specific
+    -- LYX_DMG                  = OFF    : Build as Mac bundle, needed for .dmg  (experimental)
+    -- LYX_COCOA                = OFF    : Use Cocoa on Mac
 
 
-Using the merged files build
+Using the merged files build (Deprecated)
 -----------------------------
 
     When the option 'LYX_MERGE_FILES' is used then for each library a file
@@ -241,7 +264,7 @@ Ubuntu/Kubuntu
     You need additionally these packages:
       * g++
       * cmake
-      * qt4-dev-tools
+      * qttools5-dev-tools + qt5-qmake or qt6-base-dev-tools + qt6-tools-dev
 
 
 
@@ -301,12 +324,18 @@ Packaging
         make package
 
     - Binary .deb:
-        create : cpack -G DEB --config CPackConfig.cmake
+       Configure with "cmake -DCPACK_BINARY_DEB:BOOL=ON"
+         make package
+       -- or --
+         create : cpack -G DEB --config CPackConfig.cmake
         list   : dpkg-deb -c lyx-*.deb
         install: dpkg -i lyx-*.deb
 
     - Binary .rpm:
-        create : cpack -G RPM --config CPackConfig.cmake
+       Configure with "cmake -DCPACK_BINARY_RPM:BOOL=ON"
+         make package
+       -- or --
+         create : cpack -G RPM --config CPackConfig.cmake
         list   : rpm -qlp lyx-*.rpm
         install: rpm -U lyx-*.rpm