Trying to compile Tor with 'cl' ver. 19.36.32323 from
yesterdays 'git master', I got this error in
'src/feature/hs/hs_metrics_entry.c':
hs/hs_metrics_entry.c(98,3): error C2099: initializer is not a constant
{
^
hs/hs_metrics_entry.c(106,3): error C2099: initializer is not a constant
{
^
···
----------
This MSVC compiler is rather stupid; it fails to parse that
'static const size_t hs_metrics_circ_build_time_buckets_size'
is truly 'const'. No problem with 'clang-cl'.
But this patch works:
Trying to compile Tor with 'cl' ver. 19.36.32323 from
yesterdays 'git master', I got this error in
'src/feature/hs/hs_metrics_entry.c':
hs/hs_metrics_entry.c(98,3): error C2099: initializer is not a constant
{
^
hs/hs_metrics_entry.c(106,3): error C2099: initializer is not a constant
{
^
----------
This MSVC compiler is rather stupid; it fails to parse that
'static const size_t hs_metrics_circ_build_time_buckets_size'
is truly 'const'. No problem with 'clang-cl'.
But this patch works:
While MSVC is not an officially supported build platform[1], if you want to
submit an MR for the fix, I'd be happy to review it. I would do it myself, but I
don't have an environment where I can test the proposed solution in.
Trying to compile Tor with 'cl' ver. 19.36.32323 from
yesterdays 'git master', I got this error in
'src/feature/hs/hs_metrics_entry.c':
hs/hs_metrics_entry.c(98,3): error C2099: initializer is not a constant
{
^
hs/hs_metrics_entry.c(106,3): error C2099: initializer is not a constant
{
^
----------
This MSVC compiler is rather stupid; it fails to parse that
'static const size_t hs_metrics_circ_build_time_buckets_size'
is truly 'const'. No problem with 'clang-cl'.
But this patch works:
While MSVC is not an officially supported build platform[1], if you want to
submit an MR for the fix, I'd be happy to review it. I would do it myself, but I
don't have an environment where I can test the proposed solution in.