skip to Main Content

I am trying to roll out a production Django environment on Windows 10 with Apache 2.4.37 x64 OpenSSL 1.1.1 VC14 from ApacheHaus. However, when following these instructions, I’m getting the following error:

  C:Program Files (x86)Microsoft Visual Studio2017CommunityVCToolsMSVC14.16.27023binHostX86x64cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -ID:/Servers/Web/Apache/Apache24/include -Ic:programspython37include -Ic:programspython37include "-IC:Program Files (x86)Microsoft Visual Studio2017CommunityVCToolsMSVC14.16.27023ATLMFCinclude" "-IC:Program Files (x86)Microsoft Visual Studio2017CommunityVCToolsMSVC14.16.27023include" "-IC:Program Files (x86)Windows KitsNETFXSDK4.6.1includeum" "-IC:Program Files (x86)Windows Kits10include10.0.17763.0ucrt" "-IC:Program Files (x86)Windows Kits10include10.0.17763.0shared" "-IC:Program Files (x86)Windows Kits10include10.0.17763.0um" "-IC:Program Files (x86)Windows Kits10include10.0.17763.0winrt" "-IC:Program Files (x86)Windows Kits10include10.0.17763.0cppwinrt" /Tcsrc/servermod_wsgi.c /Fobuildtemp.win-amd64-3.7Releasesrc/servermod_wsgi.obj
  mod_wsgi.c
  d:serverswebapacheapache24includeapr_network_io.h(29): fatal error C1083: Cannot open include file: 'apr_perms_set.h': No such file or directory
  error: command 'C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\HostX86\x64\cl.exe' failed with exit status 2

  ----------------------------------------
  Failed building wheel for mod-wsgi

I see the following options to C/C++ compiler: -ID:/Servers/Web/Apache/Apache24/include -Ic:programspython37include . So it seems include file apr_perms_set.h is missing from Apache or Python.

How to fix this error with the correct versions of the include files? I’m afraid it’s wrong to just take the latest version from a repository because it may not match what’s Apache or mod-wsgi expect.

3

Answers


  1. You can download the missing file from Github and copy it in the directory

    C:/Apache24/include
    
    Login or Signup to reply.
  2. I had similar error on Windows Server 2016, when trying to use Apache 2.4 64bit with Python 2.7. Apparently apr header files were missing. I was able to solve it by:

    • making sure I have both Apache and Python 64bit (guess it’ll be valid
      for 32bit as well) installing VC++
      Redistributable
      – of course 64bit in my case
    • downloading Apache Runtime (apr) headers from APR project website
    • copying missing header file from downloaded sources into Apache’s include folder
    • installing mod_wsgi with pip install mod_wsgi (inside my virtual environment).
    Login or Signup to reply.
  3. The distribution from The Apache Haus does not include the aforementioned header file for some strange reason. Try using the distribution from Apache Lounge, it should contain all header files needed to compile mod_wsgi (tested with httpd-2.4.41-win32-VS16.zip).

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search