LyX/Cygwin 2.2.4
----------------

This package provides LyX version 2.2.4 built as a Cygwin application.
Thus, a preliminary requirement is the installation of the Cygwin runtime.
Note that you need a very recent Cygwin version, at least 2.10.0 or later.
Both 32- and 64-bit versions are supported. The right packages for a
given architecture are automatically chosen by using the corresponding
setup programs (i.e., either setup-x86.exe or setup-x86_64.exe).
Before installing LyX, you should install at least the following Cygwin
packages (and all other packages pulled in by dependencies):

python2              ghostscript
file                 ImageMagick
libaspell15          texlive-collection-latexrecommended
libfreetype6         texlive-collection-latexextra
libharfbuzz0         texlive-collection-science
libhunspell1.6_0
libiconv2
libicu60
libjpeg8
libpcre2_16_0
libpng16
libgcc1
libstdc++6
zlib0

However, you must be aware that the ghostscript, ImageMagick and texlive
packages have a dependency on X11, so installing them would also pull in
the Cygwin/X server. This version of LyX does not need a X server, and if
you want to avoid it, you can simply install the native Windows version of
ghostscript (from https://www.ghostscript.com/download/gsdnld.html),
ImageMagick (from https://www.imagemagick.org/script/download.php#windows)
and MiKTeX (from https://miktex.org/), such that you could skip the installation
of the Cygwin packages listed in the second column above.

After installing the required packages, you will find instructions
on how to install LyX/Cygwin in the file INSTALL.txt.

This package contains both a wrapper for launching LyX from the Windows GUI
(in order to set up a proper environment for LyX and avoid having a terminal
window open) and a real binary for command line usage.

lyxwin-2.2.exe      wrapper, to be used from the Windows GUI
lyx-2.2.exe         real binary, to be used from the command line

The executable names have "-2.2" appended in order to allow a parallel
installation with LyX versions 2.3.x (whose binaries are not versioned).
When using the lyxwin-2.2 wrapper, its environment is set through the system
file /usr/local/share/lyx-2.2/lyxprofile. You may wish to create a file named
.lyxprofile in your home directory if you want to override the settings in the
system lyxprofile. For example, in order to specify the language to be used
in the GUI, add the line "export LANG=it_IT.UTF-8" (without the quotes) to the
file ~/.lyxprofile if you want menus in italian, or "export LANG=fr_FR.UTF-8"
(again, without quotes) for french menus.
Note that, for using the lyxwin-2.2 wrapper, the cygwin /bin directory (either
C:\cygwin\bin or C:\cygwin64\bin) should be added to the Windows system PATH.
Your home directory should be correctly guessed by the system lyxprofile, but
it is better setting the HOME variable in your Windows environment.
These are the only changes that you need doing. Please, note that you have to
use a cygwin editor for editing the system lyxprofile or ~/.lyxprofile, as a
native Windows editor may introduce wrong line endings, causing troubles with
the bash shell. Also note that until version 1.6.6 the system lyxprofile was
located in the /etc directory, but this is no more the case.

In /usr/local/share/lyx-2.2/etc/lyx.reg you will find registry entries for
associating a .lyx file to lyxwin-2.2.exe. Simply navigate to that dir using
the Windows explorer, select the file and choose "Join" or whatever the name
of that entry in your locale. An easy way for opening an explorer window at
the right location when working in a cygwin shell, is using the command
"cygstart /usr/local/share/lyx-2.2/etc".


Upgrading from previous versions
--------------------------------

Note that in order to allow a parallel installation with LyX 2.3.x, the
package name is now LyXwin22, meaning that a previous installation of LyX 2.2
will not be automatically removed. So, if you have installed LyX 2.2.3 or a
previous version, you have to either uninstall it through setup-x86*.exe or
also install LyX/Cygwin 2.3.0, which will replace the previous LyXwin package.
This also means that there's no direct upgrade path from previous versions,
unless you create a new ~/.lyx-2.2 directory and copy there the content of
your old ~/.lyx directory (pay attention to do that before launching LyX 2.3.0,
if you also want to install it). Please read the UPGRADING.txt file for further
details.

If you use Windows applications that do not understand posix paths, you need
to call them through a wrapper script in order to translate the paths to the
native Windows style.

You can find a wrapper script skeleton in /usr/local/share/lyx-2.2/etc/wrapper.sh.
Simply give it the same name of your Windows application (without any
extension), and then place it in /usr/local/bin. Now edit it using a cygwin
text editor and change command_name in the last line with the full path
to the Windows application with the same name. That's it.
The wrapper should work with the vast majority of applications.

Dictionaries and Thesauri
-------------------------
The LyXdict package contains only a couple of dictionaries and thesauri files
(english and italian). However, you can download the files for your language
from http://www.lyx.org/trac/browser/dictionaries/trunk/dicts
and  http://www.lyx.org/trac/browser/dictionaries/trunk/thes
(you need four files per language, those with extensions .aff and .dic for
the dictionaries and .dat and .idx for the thesauri) and put them into the
/usr/local/share/dict/ and /usr/local/share/thes/ directories, respectively.
However, these locations can be configured in the preferences.


Disclaimer
----------

This package works for me but I cannot guarantee that it does for you, or
even that, by using it, your computer will not blow up in smoke ;-)

-- 
Enrico Forestieri, March 2018

