Use specified Perl interpreter instead of relying on PATH
ClosedPublic

Authored by zrax on Oct 3 2018, 6:02 PM.

Details

Summary

If a PERL_EXECUTABLE is passed on the CMake command line, e.g. because the default one in PATH is insufficient, kdoctools would still use the one in PATH incorrectly. This fixes it to use the specified perl both at configure time and at build / install time.

Diff Detail

Repository
R238 KDocTools
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
zrax created this revision.Oct 3 2018, 6:02 PM
Restricted Application added projects: Frameworks, Documentation. · View Herald TranscriptOct 3 2018, 6:02 PM
Restricted Application added a subscriber: kde-doc-english. · View Herald Transcript
zrax requested review of this revision.Oct 3 2018, 6:02 PM
vonreth added a subscriber: vonreth.Oct 3 2018, 6:28 PM

Please fallback on looking up perl from path if that perl does not exists.
Purely relying on a hardcoded path would break the capability of relocating kdoctools.

zrax added a comment.Oct 3 2018, 9:18 PM

PERL_EXECUTABLE is set by cmake's FindPerl module (https://cmake.org/cmake/help/v3.0/module/FindPerl.html), so it should always be defined. This only fixes the case where it's overridden on the command line (or cmake-gui, etc).

ah sorry I took this for a config file, everything is fine then.

Note to myself: Don't review code on the phone....

ltoscano accepted this revision.Oct 4 2018, 7:28 PM
ltoscano added a subscriber: ltoscano.

Uhm, I guess than this can go in then.

This revision is now accepted and ready to land.Oct 4 2018, 7:28 PM
This revision was automatically updated to reflect the committed changes.