Am Sun, 15 Nov 2020 20:16:49 +0100
schrieb Yu Jin <yu_...@lyx.org>:

> Am So., 15. Nov. 2020 um 20:15 Uhr schrieb Yu Jin <yu_...@lyx.org>:
> 
> > Am So., 15. Nov. 2020 um 18:20 Uhr schrieb Thibaut Cuvelier <
> > tcuvel...@lyx.org>:
> >
> >> On Sun, 15 Nov 2020 at 16:59, Kornel Benko <kor...@lyx.org> wrote:
> >>
> >>> Am Sun, 15 Nov 2020 16:47:36 +0100
> >>> schrieb Yu Jin <yu_...@lyx.org>:
> >>>
> >>> > Am So., 15. Nov. 2020 um 16:34 Uhr schrieb Yu Jin <yu_...@lyx.org>:
> >>> >
> >>> > > Am So., 15. Nov. 2020 um 16:03 Uhr schrieb Kornel Benko <
> >>> kor...@lyx.org>:
> >>> > >
> >>> > >> Am Sun, 15 Nov 2020 15:08:43 +0100
> >>> > >> schrieb Yu Jin <yu_...@lyx.org>:
> >>> > >>
> >>> > >> > > You have to investigate the cmake module FomdPerl.cmake.
> >>> > >> > > It may help, if you use HINTS, for instance for path D:\xxxx
> >>> > >> > >         find_package(Perl REQUIRED PATHS "D:\\xxxx")
> >>> > >> > >
> >>> > >> > > At least, this one works on linux too.
> >>> > >> > >
> >>> > >> > Uhm, ist it possible that CMake looks for a CMake configuration
> >>> file
> >>> > >> for perl and not
> >>> > >> > the perl.exe? I get this with your proposal:
> >>> > >> >
> >>> > >> > CMake Error at CMakeLists.txt:1216 (find_package):
> >>> > >> >   Could not find a package configuration file provided by "Perl"
> >>> with
> >>> > >> any of
> >>> > >> >   the following names:
> >>> > >> >
> >>> > >> >     PerlConfig.cmake
> >>> > >> >     perl-config.cmake
> >>> > >> >
> >>> > >> >   Add the installation prefix of "Perl" to CMAKE_PREFIX_PATH or
> >>> set
> >>> > >> >   "Perl_DIR" to a directory containing one of the above files.  If
> >>> > >> "Perl"
> >>> > >> >   provides a separate development package or SDK, be sure it has
> >>> been
> >>> > >> >   installed.
> >>> > >> >
> >>> > >> >
> >>> > >> > Content of FindPerl.cmake:
> >>> > >> >
> >>> > >> > # Distributed under the OSI-approved BSD 3-Clause License.  See
> >>> > >> accompanying
> >>> > >> > # file Copyright.txt or https://cmake.org/licensing for details.
> >>> > >> >
> >>> > >>
> >>> > >> The module FindPerl.cmake is the same as here. Also I don't have
> >>> neither
> >>> > >> PerlConfig.cmake nor perl-config.cmake anywhere on my system. So I
> >>> > >> wonder, why
> >>> > >> your cmake does not use this module. Could You add some
> >>> message(STATUS
> >>> > >> ...) inside the
> >>> > >> module?
> >>> > >>
> >>> > >> You could copy FindPerl.cmake to our development/cmake/modules and
> >>> modify
> >>> > >> there too.
> >>> > >>
> >>> > >
> >>> > > Added the messages, it uses this module when I don't modify
> >>> > > CMakeLists.txt. But when I add the PATHS part to the find_package
> >>> command,
> >>> > > this module is not used anymore, the messages don't show up.
> >>> > >
> >>> > What works though is to add the path to perl to CMAKE_PREFIX_PATH, I
> >>> just
> >>> > added "C:/lyx/lyx-windows-deps-msvc2019_64/perl",
> >>> > "C:/lyx/lyx-windows-deps-msvc2019_64" used to be the GNUWIN32_DIR
> >>> earlier.
> >>>
> >>> Nice. I would add it to some extra module guarded by 'if(WIN32)'
> >>>
> >>
> >> I'm having the same issue if I don't give CMake the path to Perl (via
> >> PERL_EXECUTABLE), even though CMake's FindPerl should be looking at the
> >> exact place where my Perl is installed, which is really standard
> >> (C:\Strawberry\perl\bin\perl.exe and perl5.32.0.exe:
> >> https://github.com/Kitware/CMake/blob/master/Modules/FindPerl.cmake#L32).
> >> I think that  CMAKE_PREFIX_PATH is not the right fix for this issue, but my
> >> CMake proficiency is too low to help on this issue.
> >>
> >
> > I agree with CMAKE_PREFIX_PATH. I think that GNUWIN32_DIR was a good way
> > of handling that (I assume it was that way), because the dependencies are
> > needed anyway to run LyX and/or build the installer and we offer them for
> > download. May I ask why it got removed?
> > I mean it actually makes sense to add path to Perl to the pathprefix, but
> > it is an individual setting if the Windows PATH variable does not contain
> > it. So I would need to make that setting in CMake anyway, so why not just
> > point it directly to GNUWIN32_DIR instead of Perl?
> >
> Sorry, I meant "I agree with the CMAKE_PREFIX_PATH part".

I don't understand. The GNUWIN32_DIR is set at CMakeLists.txt:9 (as it was 
before), I
didn't remove this setting.

        Kornel

Attachment: pgpnmTpdKEqIX.pgp
Description: Digitale Signatur von OpenPGP

-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel

Reply via email to