In brief:
C2146, C2065, C2040 errors when building Timescale 2.9.3 from source on Windows machine
TimescaleDB version:
2.9.3
PostgreSQL version:
13
Other software:
OS:
Windows
Platform:
Install method: [Source|Docker|Deb/Apt|RPM|Homebrew|Other|Not relevant]
Source
Environment: [Production, Test, Development]
Development
I have an existing Postgres 13 database installed on my localhost. I would like to add Timescale to a couple tables within that database without needing to migrate the entire database to Timescale. I am following the “Self-Hosted From Source” instructions, but receive errors when I build the extension. Here are some of the errors I receive:
$ cmake --build ./build --config Release
Microsoft (R) Build Engine version 15.9.21+g9802d43bc3 for .NET Framework
Copyright (C) Microsoft Corporation. All rights reserved.
timescaledb.vcxproj → C:\sites\timescaledb\build\src\Release\timescaledb-2.9.3.dll
timescaledb-loader.vcxproj → C:\sites\timescaledb\build\src\loader\Release\timescaledb.dll
dist_copy.c
C:\sites\timescaledb\tsl\src\remote\dist_copy.c(1106): error C2146: syntax error: missing ‘;’ before identifier ‘fields’ [C:\sites\timescaledb\build\tsl\src\timescaledb-tsl.vcxproj]
C:\sites\timescaledb\tsl\src\remote\dist_copy.c(1106): error C2065: ‘fields’: undeclared identifier [C:\sites\timescaledb\build\tsl\src\timescaledb-tsl.vcxproj]
C:\sites\timescaledb\tsl\src\remote\dist_copy.c(1106): warning C4047: ‘=’: ‘int’ differs in levels of indirection from ‘char **’ [C:\sites\timescaledb\build\tsl\src\timescaledb-tsl.vcxproj]
C:\sites\timescaledb\tsl\src\remote\dist_copy.c(1107): error C2040: ‘restrict’: ‘char *’ differs in levels of indirection from ‘char **’ [C:\sites\timescaledb\build\tsl\src\timescaledb-tsl.vcxproj]
C:\sites\timescaledb\tsl\src\remote\dist_copy.c(1107): error C2146: syntax error: missing ‘;’ before identifier ‘output’ [C:\sites\timescaledb\build\tsl\src\timescaledb-tsl.vcxproj]
C:\sites\timescaledb\tsl\src\remote\dist_copy.c(1107): error C2065: ‘output’: undeclared identifier [C:\sites\timescaledb\build\tsl\src\timescaledb-tsl.vcxproj]
C:\sites\timescaledb\tsl\src\remote\dist_copy.c(1107): warning C4047: ‘=’: ‘int’ differs in levels of indirection from ‘char *’ [C:\sites\timescaledb\build\tsl\src\timescaledb-tsl.vcxproj]
C:\sites\timescaledb\tsl\src\remote\dist_copy.c(1111): error C2146: syntax error: missing ‘;’ before identifier ‘src’ [C:\sites\timescaledb\build\tsl\src\timescaledb-tsl.vcxproj]
I have then tried to continue with the installation process and install TimescaleDB, but that results in similar errors