Commit Graph

6 Commits

Author SHA1 Message Date
Gerald Combs 6a16f158c8 CMake: Look for Python in more places.
According to PEP 514, Python.org's Windows installer stores its
installation path in

HKEY_LOCAL_MACHINE\Software\Python\<Company>\<Tag>\InstallPath

where <Tag> is the value of sys.winver. Newer versions of python add "-32"
and "-64" to the version in order to allow side by side installations.
Adjust LocatePythonExecutable accordingly.

Change-Id: I8c7f8b4c31b37e7f687ce9909f97d62a779cfa91
Reviewed-on: https://code.wireshark.org/review/22048
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2017-06-08 22:41:20 +00:00
Guy Harris 6375df2da4 Put a newline at the end of the file.
Change-Id: Ic04e9a4afdceb1e36ad8367dd0d7bf6bd0674844
Reviewed-on: https://code.wireshark.org/review/11514
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-11-03 01:46:41 +00:00
Gerald Combs 5c5cc228fc Revert the last two CMake changes.
get_filename_component returns "/regstry" if the query is unsuccessful.
We'll have to add a check for that if we query "Add Paths".

Revert "CMake: Pass ABSOLUTE to get_filename_component."

This reverts commit 4c03f4be00.

Revert "CMake: Look for Python using the "App Paths" key."

This reverts commit 6d1b6cd39d.

Change-Id: Ida17608467fa3652f4219e4eaf01edfa48120b1d
Reviewed-on: https://code.wireshark.org/review/11512
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-11-03 01:35:28 +00:00
Gerald Combs 4c03f4be00 CMake: Pass ABSOLUTE to get_filename_component.
Change-Id: Iecfc4aabe332cac930a7fa5bb6e342a55e7bc7b3
Reviewed-on: https://code.wireshark.org/review/11510
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-11-03 01:09:23 +00:00
Gerald Combs 6d1b6cd39d CMake: Look for Python using the "App Paths" key.
Query HKLM\Software\Microsoft\Windows\CurrentVersion\App Paths\Python.exe
and HKCU\Software\Microsoft\Windows\CurrentVersion\App Paths\Python.exe
first before trying other methods.

Change-Id: I83f54f6833149c68f1626c3c17f25ffe54d8ea5d
Reviewed-on: https://code.wireshark.org/review/11506
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-11-03 00:37:29 +00:00
Gerald Combs 7682ae4887 Keep CMake from finding Cygwin's Python.
Try to find Python and set PYTHON_EXECUTABLE on Windows via the registry
prior to calling FindPythonInterp. This works around a bug in CMake that
prefers Cygwin's Python, which is a symlink, which by default is a text
file that contains a Cygwin-specific cookie, which is therefore useless
outside of Cygwin.

This is avoids the need to pass -DPYTHON_EXECUTABLE=... to CMake.

Change-Id: Ife37221b61d920682c20357b6d139a93067a5ad1
Reviewed-on: https://code.wireshark.org/review/11071
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-16 20:40:28 +00:00