Hi All,
I am trying to build pypostal on Windows and have successfully built the postal.lib but when I attempt to "pip install postal" I get this error. Any ideas on how to fix this please?
"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\bin\HostX86\x64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD -I/usr/local/include -IC:\dev\libpostal\headers\include "-IC:\Users\My ser\miniconda3\envs\myenv\include" "-IC:\Users\My ser\miniconda3\envs\myenv\Include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\ATLMFC\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\cppwinrt" "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\ATLMFC\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.28.29333\include" "-IC:\Program Files (x86)\Windows Kits\NETFXSDK\4.8\include\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\shared" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\um" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\winrt" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.18362.0\cppwinrt" /Tcpostal/pyexpand.c /Fobuild\temp.win-amd64-cpython-39\Release\postal/pyexpand.obj -std=c99
cl : Command line warning D9002 : ignoring unknown option '-std=c99'
pyexpand.c
C:\dev\libpostal\headers\include\stdio.h(577): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdio.h(584): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdio.h(590): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdio.h(851): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdio.h(881): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdio.h(1235): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdio.h(1242): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdio.h(1248): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdio.h(1364): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdio.h(1374): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\swprintf.inl(27): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\swprintf.inl(34): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdlib.h(389): error C2085: '_exit': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(389): error C2143: syntax error: missing ';' before 'type'
C:\dev\libpostal\headers\include\stdlib.h(396): error C2085: '_Exit': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(396): error C2143: syntax error: missing ';' before 'type'
C:\dev\libpostal\headers\include\stdlib.h(399): error C2085: '_Exit': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(399): error C2143: syntax error: missing ';' before '{'
C:\dev\libpostal\headers\include\stdlib.h(399): warning C4013: '_exit' undefined; assuming extern returning int
C:\dev\libpostal\headers\include\stdlib.h(399): error C2065: 'status': undeclared identifier
C:\dev\libpostal\headers\include\stdlib.h(405): error C2059: syntax error: 'type'
C:\dev\libpostal\headers\include\stdlib.h(683): error C2491: '_beep': definition of dllimport function not allowed
C:\dev\libpostal\headers\include\stdlib.h(685): error C2085: '_seterrormode': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(685): error C2143: syntax error: missing ';' before 'type'
C:\dev\libpostal\headers\include\stdlib.h(686): error C2085: '_sleep': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(686): error C2143: syntax error: missing ';' before 'type'
C:\dev\libpostal\headers\include\stdlib.h(707): error C2085: 'ecvt': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(708): error C2085: 'fcvt': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(709): error C2085: 'gcvt': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(710): error C2085: 'itoa': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(711): error C2085: 'ltoa': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(712): error C2085: 'putenv': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(716): error C2085: 'swab': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(719): error C2085: 'ultoa': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(720): error C2085: 'onexit': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(726): error C2085: 'lldiv_t': not in formal parameter list
C:\dev\libpostal\headers\include\stdlib.h(728): error C2061: syntax error: identifier 'lldiv_t'
C:\dev\libpostal\headers\include\stdlib.h(732): error C2169: 'llabs': intrinsic function, cannot be defined
C:\dev\libpostal\headers\include\mm_malloc.h(32): error C2054: expected '(' to follow '__inline__'
C:\dev\libpostal\headers\include\mm_malloc.h(34): error C2085: '_mm_malloc': not in formal parameter list
C:\dev\libpostal\headers\include\mm_malloc.h(34): error C2143: syntax error: missing ';' before '{'
C:\dev\libpostal\headers\include\mm_malloc.h(72): error C2054: expected '(' to follow '__inline__'
C:\dev\libpostal\headers\include\mm_malloc.h(73): error C2085: '_mm_free': not in formal parameter list
C:\dev\libpostal\headers\include\mm_malloc.h(73): error C2143: syntax error: missing ';' before '{'
C:\dev\libpostal\headers\include\malloc.h(125): error C2065: '_ALLOCA_S_MARKER_SIZE': undeclared identifier
C:\dev\libpostal\headers\include\malloc.h(144): error C2065: '_ALLOCA_S_MARKER_SIZE': undeclared identifier
C:\dev\libpostal\headers\include\math.h(209): error C2065: '__asm__': undeclared identifier
C:\dev\libpostal\headers\include\math.h(209): error C2146: syntax error: missing ';' before identifier '__volatile__'
C:\dev\libpostal\headers\include\math.h(209): warning C4013: '__volatile__' undefined; assuming extern returning int
C:\dev\libpostal\headers\include\math.h(209): error C2143: syntax error: missing ')' before ':'
C:\dev\libpostal\headers\include\math.h(220): error C2065: '__asm__': undeclared identifier
C:\dev\libpostal\headers\include\math.h(220): error C2146: syntax error: missing ';' before identifier '__volatile__'
C:\dev\libpostal\headers\include\math.h(220): error C2143: syntax error: missing ')' before ':'
C:\dev\libpostal\headers\include\math.h(226): error C2169: 'fabs': intrinsic function, cannot be defined
C:\dev\libpostal\headers\include\math.h(682): error C2169: 'sinhf': intrinsic function, cannot be defined
C:\dev\libpostal\headers\include\math.h(688): error C2169: 'coshf': intrinsic function, cannot be defined
C:\dev\libpostal\headers\include\math.h(694): error C2169: 'tanhf': intrinsic function, cannot be defined
C:\dev\libpostal\headers\include\math.h(718): error C2169: 'expf': intrinsic function, cannot be defined
C:\dev\libpostal\headers\include\math.h(891): error C2169: 'powf': intrinsic function, cannot be defined
C:\dev\libpostal\headers\include\math.h(1157): error C2065: '__asm__': undeclared identifier
C:\dev\libpostal\headers\include\math.h(1157): error C2146: syntax error: missing ';' before identifier '__volatile__'
C:\dev\libpostal\headers\include\math.h(1158): error C2143: syntax error: missing ')' before ':'
C:\dev\libpostal\headers\include\sys/types.h(68): error C2371: 'pid_t': redefinition; different basic types
C:\Users\My ser\miniconda3\envs\myenv\include\pyconfig.h(190): note: see declaration of 'pid_t'
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.28.29333\\bin\\HostX86\\x64\\cl.exe' failed with exit code 2
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> postal
note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
Hi All,
I am trying to build pypostal on Windows and have successfully built the postal.lib but when I attempt to "pip install postal" I get this error. Any ideas on how to fix this please?
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> postal
note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.