X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=INSTALL.Win32;h=13730972dc3ef15d4cf935e8bf4a63a4a43881ec;hb=665405da0a4d238ec998c5122e84efaca98a51a8;hp=ed6a2c75d654c8255a098274e8d5041ef0d1ad2b;hpb=0aab8ead34b4128c27e5452294fc08810d658364;p=lyx.git diff --git a/INSTALL.Win32 b/INSTALL.Win32 index ed6a2c75d6..13730972dc 100644 --- a/INSTALL.Win32 +++ b/INSTALL.Win32 @@ -1,141 +1,112 @@ -================= -INSTALL for Win32 -================= +Compiling LyX 2.0 for Win32 and creating Windows installer +========================================================== -Building LyX the first time can appear to be a daunting task, but much of -that is knowing which packages to download in the first place. +It's recommended to compile LyX using Microsoft Visual C++ 2010 and CMake. +Pre-compiled packages with dependencies are provided for this environment. -The instructions below should guide you through the installation of -the MinGW/MinSYS build environment, together with details on how to -grab and build the Qt toolkit and how to grab Aspell and LyX. -Once you've done all that, you should go read the README in -development/Win32/packaging/ The two scripts in the same directory, -build_lyxwin.sh and package_lyxwin.sh should automate the entire -build process. If not and you really can't figure out what to do next, -then please, please drop a mail to lyx-devel@lists.lyx.org. +Compiling with Microsoft Visual C++ +=================================== -Enjoy! -The LyX Team + These instructions assume the LyX source code is installed in C:\LyX\lyx-20 + You can also use another directory if you prefer. -============================================================================= -1 MinGW & MSYS +1 Install MSVC 2010 -1.1 Download the following packages from http://www.mingw.org/download.shtml: + If you don't have Visual C++ 2010 installed, get the free Express edition from + http://www.microsoft.com/express/Downloads/ - MinGW-3.2.0-rc-3.exe - binutils-2.15.94-20050118-1.tar.gz - MSYS-1.0.11-2004.04.30-1.exe - msysDTK-1.0.1.exe + All dependencies are linked against the MSVC 2010 runtime and won't work in + combination with MSVC 2008. You'll get crashes and other unexpected issues. -1.2 Install MinGW-3.2.0-rc-3.exe in C:\MinGW +2 Compile Qt -1.3 Install MSYS-1.0.11-2004.04.30-1.exe in C:\msys + Download the latest Qt everywhere open source version from + http://get.qt.nokia.com/qt/source/ (e.g. qt-everywhere-opensource-src-4.7.1.zip). + Follow the instructions on http://doc.qt.nokia.com/4.7/install-win.html to + compile using MSVC 2010. + The pre-compiled version of Qt cannot be used. It uses the 2008 version of the + MSVC runtime which will result in crashes. -1.4 Install msysDTK-1.0.1 in C:\msys +3 Install Python -1.5 Extract binutils-2.15.94-20050118-1.tar.gz in C:\MinGW - (i.e., overwrite the existing binutils) + Install the latest Python 2.x version from + http://www.python.org/download/ +4 Install CMake -2. Gettext & Libiconv + Install the latest CMake from http://www.cmake.org -2.1 Download the following packages from - http://www.gnu.org/software/gettext/gettext.html: +5 Configure - gettext-tools-0.13.1.bin.woe32.zip - gettext-runtime-0.13.1.bin.woe32.zip - libiconv-1.9.1.bin.woe32.zip + - Run the CMake GUI. + + - Set the source code path to C:\LyX\lyx-20 + Set the build path to C:\LyX\lyx-20-build + Click Configure and set the generator to Visual Studio 10. -2.2 Extract the three packages in C:\MinGW + - Enable LYX_DEPENDENCIES_DOWNLOAD and click Configure. + Pre-compiled dependencies will automatically be downloaded. + + - Set QT_QMAKE_EXECUTABLE to e.g. + C:\Qt\qt-everywhere-opensource-src-4.7.1\bin\qmake.exe + and Configure again. + - Enable the LYX_INSTALL option, set CMAKE_INSTALL_PREFIX to + C:\LyX\lyx-20-install and click Configure. + - Check the Advanced checkbox. + Set GETTEXT_MSGFMT_EXECUTABLE to + C:\LyX\lyx-20-build\msvc2010-deps\deps20\gettext-tools\msgfmt.exe, + and do the same for the other gettext tools. -3 QT/Win Free Edition - http://qtwin.sourceforge.net/index.php/QT/Free_from_CVS_with_Mingw + - Click Generate. -3.1 Get the latest CVS version +6 Compile - Using the cvs executable that is packaged with MinSYS, - from the MinSYS command prompt: + A Microsoft Visual C++ solution should have been generated at + C:\LyX\lyx-20-build\lyx.sln + Compile the INSTALL project to get a LyX installation in + C:\LyX\lyx-20-install - $ cd ~ - $ cvs -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/kde-cygwin login - (no password) - $ cvs -z3 -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/kde-cygwin co \ - -r QT_WIN32_3_3_BRANCH -d qt3 qt-3 +7 Copy dependencies - Alternatively, use the TortoiseCVS graphical interface. + Copy + - C:\LyX\lyx-20-build\msvc2010-deps\deps20\bin + - C:\LyX\lyx-20-build\msvc2010-deps\deps20\imagemagick + - C:\LyX\lyx-20-build\msvc2010-deps\deps20\python + - C:\LyX\lyx-20-build\msvc2010-deps\deps20\ghostscript + - C:\LyX\lyx-20-build\msvc2010-deps\deps20\Resources + to C:\LyX\lyx-20-install -3.2 Compile the QT library + And copy from the Qt bin directory + (e.g. C:\Qt\qt-everywhere-opensource-src-4.7.1\bin) + QtCore4.dll + QtGui4.dll + QtCore4d.dll (if compiling Debug version) + QtGui4d.dll (if compiling Debug version) + to C:\LyX\lyx-20-install\bin - Create two .bat files, in the top-level directory of the Qt tree, - my_configure.bat and my_make.bat. Mine are shown below. Obviously, - you'll have to tweak them ;-) +8 Define path prefix - $ cat my_configure.bat - set QTDIR=J:\MinSys\home\Angus\qt3 - set MINGW=J:\MinGW - set PATH=J:\MinSys\home\Angus\qt3\bin;J:\MinGW\bin;C:\WINDOWS\system32;C:\WINDOWS - set QMAKESPEC=win32-g++ - configure.bat -verbose + Add the following line to C:\LyX\lyx-20-install\Resources\lyxrc.dist, + so LyX will find the bundled tools such as Python, ImageMagick + and Ghostscript: - $ cat my_make.bat - set QTDIR=J:\MinSys\home\Angus\qt3 - set MINGW=J:\MinGW - set PATH=J:\MinSys\home\Angus\qt3\bin;J:\MinGW\bin;C:\WINDOWS\system32;C:\WINDOWS - set QMAKESPEC=win32-g++ - mingw32-make symlinks - mingw32-make src-moc - mingw32-make sub-src + \path_prefix "$LyXDir\bin;$LyXDir\python;$LyXDir\imagemagick;$LyXDir\ghostscript" - The first time that you build the Qt sources, run my_configure.bat. - Thereafter, you should be able to get away with my_make.bat. If it fails, - you should try my_configure.bat again, but this will overwrite all the - Qt header files, so you'll end up rebuilding large chunks of LyX as well. + You may also add the location of your LaTeX installation if it's not on the + system PATH, and the location of JabRef. - $ cmd.exe - PROMPT> my_configure.bat +9 Start LyX -4. Aspell + C:\LyX\lyx-20-install\bin\lyx.exe -4.1 Download aspell-0.50.5.tar.gz from ftp://ftp.gnu.org/gnu/aspell/ - (note: version 0.60.2 does not compile) - Download dictionaries from ftp://ftp.gnu.org/gnu/aspell/dict/ - Eg: en/aspell-en-0.50-2.tar.bz2 - de/aspell-de-0.50-2.tar.bz2 -4.2 Extract all files in your MSYS home directory. From the - MinSYS command prompt: +Creating the Installer +====================== - $ gunzip aspell-0.50.5.tar.gz - $ bunzip2 aspell-en-0.50-2.tar.bz2 - $ tar xvf aspell-0.50.5.tar - $ tar xvf aspell-en-0.50-2.tar - $ rm -f aspell-0.50.5.tar - $ rm -f aspell-en-0.50-2.tar - - There's no need to build Aspell now. The script in - development/Win32/packaging should do it for you. - -5. LyX - -5.1 Get the latest CVS version - - Using the cvs executable that is packaged with MinSYS, - from the MinSYS command prompt: - - $ cd ~ - $ mkdir lyx && cd lyx - $ cvs -d:pserver:anoncvs@anoncvs.us.lyx.org:/cvs/lyx login - (The password is "lyx" (no inverted commas)) - $ cvs -d:pserver:anoncvs@anoncvs.us.lyx.org:/cvs/lyx \ - checkout -r BRANCH_1_3_X -d 13x lyx-devel - - Alternatively, use the TortoiseCVS graphical interface. - - There's no need to build LyX now. The script in - development/Win32/packaging should do it for you. - -Now go read the README in development/Win32/packaging. -============================================================================= + - Get NSIS from http://nsis.sourceforge.net + - In the LyX source directory, go to development\Win32\packaging\installer + - Check whether the file locations in settings.nsh match your setup. + - Right-click on lyx.nsi and click "Compile NSIS Script".