Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

aarch64 / i686 builds fail of v2.6.2 (narrowing conversion of timeout in clickhouse) #4550

Open
ignatenkobrain opened this issue May 18, 2024 · 2 comments

Comments

@ignatenkobrain
Copy link

Hello,

Maintainer of ProxySQL in Fedora here.

I was updating Fedora package to 2.6.2 but builds of aarch64 (ARM64) and i686 (i386) failed miserably…

/builddir/build/BUILD/proxysql-2.6.2/deps/clickhouse-cpp/clickhouse-cpp/clickhouse/base/socket.cpp:117:63: error: narrowing conversion of ‘(timeout_params.clickhouse::SocketTimeoutParams::recv_timeout.std::chrono::duration<long long int, std::ratio<1, 1000> >::count() / 1000)’ from ‘std::chrono::duration<long long int, std::ratio<1, 1000> >::rep’ {aka ‘long long int’} to ‘__time_t’ {aka ‘long int’} [-Werror=narrowing]
  117 |     timeval recv_timeout{ timeout_params.recv_timeout.count() / 1000, static_cast<int>(timeout_params.recv_timeout.count() % 1000 * 1000) };
      |                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
/builddir/build/BUILD/proxysql-2.6.2/deps/clickhouse-cpp/clickhouse-cpp/clickhouse/base/socket.cpp:120:63: error: narrowing conversion of ‘(timeout_params.clickhouse::SocketTimeoutParams::send_timeout.std::chrono::duration<long long int, std::ratio<1, 1000> >::count() / 1000)’ from ‘std::chrono::duration<long long int, std::ratio<1, 1000> >::rep’ {aka ‘long long int’} to ‘__time_t’ {aka ‘long int’} [-Werror=narrowing]
  120 |     timeval send_timeout{ timeout_params.send_timeout.count() / 1000, static_cast<int>(timeout_params.send_timeout.count() % 1000 * 1000) };
      |                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~

I think including ClickHouse/clickhouse-cpp#337 should help but didn't test it yet.

Thanks in advance!

ignatenkobrain added a commit to ignatenkobrain/proxysql that referenced this issue May 18, 2024
ignatenkobrain added a commit to ignatenkobrain/proxysql that referenced this issue May 18, 2024
ignatenkobrain added a commit to ignatenkobrain/proxysql that referenced this issue May 18, 2024
ignatenkobrain added a commit to ignatenkobrain/proxysql that referenced this issue May 18, 2024
@mirostauder
Copy link
Collaborator

Hi Igor,
we don't experience any issues on daily aarch64 builds for fedora 38 and 39
can you share some details? perhaps the issue related to fedora 40?

Also we don't recommend 32bit builds like i686, as they are completely untested.

@ignatenkobrain
Copy link
Author

@mirostauder in fact, I was building it on Fedora 41 (rawhide). The i686 has different issues so I have disabled it but these 2 patches are needed to make it building on ARM64 on Rawhide

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants