[MacPorts] #62488: py38-scipy - vodemodule.c - fatal error: 'threads.h' not found

MacPorts noreply at macports.org
Mon May 17 14:04:23 UTC 2021


#62488: py38-scipy -  vodemodule.c - fatal error: 'threads.h' not found
-------------------------+-----------------------
  Reporter:  dyne2meter  |      Owner:  michaelld
      Type:  defect      |     Status:  assigned
  Priority:  Normal      |  Milestone:
 Component:  ports       |    Version:  2.6.4
Resolution:              |   Keywords:  elcapitan
      Port:  py-scipy    |
-------------------------+-----------------------

Comment (by michaelld):

 I just attached a patch (-p0) that one can apply to the top-level work
 directory for py37+ SciPy ... it forces disabling C11 STDC THREADS, so
 that the `fatal error: threads.h: No such file or directory` goes away &
 SciPy builds cleanly. I think there has to be a better solution to fix the
 issue in SciPy, but in all of my playing around with the MP Portfile &
 settings I couldn't work out a better way ... except to patch the code in
 NumPy, which maybe really is the right way to go ... IDK!

 For folks who want to give this patch a try, here's how I'd recommend you
 do it .. (1) download the patch; I'll assume it is downloaded under it's
 current name into `~/Downloads/.` ...
 {{{
 sudo port clean py38-scipy
 sudo port patch py38-scipy
 pushd $(port work py38-scipy)/scipy-scipy*
 patch -p0 < ~/Downloads/patch-add-STDC_NO_THREADS.diff
 popd
 sudo port install py38-scipy
 }}}
 and that should install cleanly now. You can also do `upgrade`, wait until
 the upgrade errors out, then apply the patch & reissue the `update` ...
 which should then work. For any `patch`, `install`, `upgrade` (etc) make
 sure the variants are what you want and are consistent, otherwise `port`
 will complain at you ;)

-- 
Ticket URL: <https://trac.macports.org/ticket/62488#comment:17>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list