Bug 236335 - cad/kicad-devel unhappy with default Python 3
Summary: cad/kicad-devel unhappy with default Python 3
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Michael Reifenberger
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-03-06 18:52 UTC by George Mitchell
Modified: 2019-03-11 19:35 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (mr)


Attachments
Allow kicad-devel configure to find python 2.7 instead of 2.6. (460 bytes, patch)
2019-03-06 18:52 UTC, George Mitchell
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description George Mitchell 2019-03-06 18:52:53 UTC
Created attachment 202660 [details]
Allow kicad-devel configure to find python 2.7 instead of 2.6.

I recently changed the default Python version to 3.6 after having stuck with 2.7 for long enough (probably too long) -- but 2.7 is still installed.  However, kicad-devel fruitlessly searches for version 2.6, finds 3.6, and gives up in the configuration phase.  The attached patch solves the problem.  (I wouldn't be surprised if this also applies to kicad as well as kicad-devel.)
Comment 1 Michael Reifenberger freebsd_committer freebsd_triage 2019-03-10 09:27:35 UTC
Hi,
I have updatet the port to the most recent version of kicad.
Is the patch still needed (I can't currently test python 3.*)
Comment 2 George Mitchell 2019-03-10 20:34:03 UTC
Yes, the latest version still fails at the configure step like this:

-- Found PythonInterp: /usr/local/bin/python (found suitable version "3.6.8", minimum required is "2.6") 
-- Check for installed Python Interpreter -- found
CMake Error at CMakeLists.txt:680 (message):
  Python 2.x is required.


-- Configuring incomplete, errors occurred!
See also "/usr/ports/cad/kicad-devel/work/kicad-source-mirror-00a9b662f7ac48d747c4dda7d0eecd678d2ca4e6/CMakeFiles/CMakeOutput.log".
See also "/usr/ports/cad/kicad-devel/work/kicad-source-mirror-00a9b662f7ac48d747c4dda7d0eecd678d2ca4e6/CMakeFiles/CMakeError.log".
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/cad/kicad-devel
*** Error code 1

Stop.
make: stopped in /usr/ports/cad/kicad-devel

As before, the problem is that the configure script doesn't consider python 2.7 to be acceptable.  When 3.x is the default version, it goes looking explicitly for version 2.6 (which typically won't be available).  The patch makes it happy with 2.7.
Comment 3 commit-hook freebsd_committer freebsd_triage 2019-03-11 16:08:59 UTC
A commit references this bug:

Author: mr
Date: Mon Mar 11 16:08:35 UTC 2019
New revision: 495358
URL: https://svnweb.freebsd.org/changeset/ports/495358

Log:
  Allow kicad-devel configure to find python 2.7 instead of 2.6

  PR:		236335
  Submitted by:	george@m5p.com

Changes:
  head/cad/kicad-devel/files/patch-CMakeLists.txt
Comment 4 George Mitchell 2019-03-11 19:35:56 UTC
Commit 495358 fixes the problem, so I am closing the bug (assuming I am allowed to do that).