Bug#1085145: libnet-kafka-perl FTBFS on 32-bit with gcc 14

Adrian Bunk bunk at debian.org
Tue Oct 15 13:12:18 BST 2024


Source: libnet-kafka-perl
Version: 1.06-2
Severity: serious
Tags: ftbfs patch

https://buildd.debian.org/status/logs.php?pkg=libnet-kafka-perl&ver=1.06-2%2Bb1

...
Kafka.xs: In function ‘XS_Net__Kafka_query_watermark_offsets’:
Kafka.xs:423:75: error: passing argument 4 of ‘rd_kafka_query_watermark_offsets’ from incompatible pointer type [-Wincompatible-pointer-types]
  423 |         err = rd_kafka_query_watermark_offsets(rdk->rk, topic, partition, &low, &high, timeout_ms);
      |                                                                           ^~~~
      |                                                                           |
      |                                                                           long int *
/usr/include/librdkafka/rdkafka.h:3316:43: note: expected ‘int64_t *’ {aka ‘long long int *’} but argument is of type ‘long int *’
 3316 |                                  int64_t *low,
      |                                  ~~~~~~~~~^~~
Kafka.xs:423:81: error: passing argument 5 of ‘rd_kafka_query_watermark_offsets’ from incompatible pointer type [-Wincompatible-pointer-types]
  423 |         err = rd_kafka_query_watermark_offsets(rdk->rk, topic, partition, &low, &high, timeout_ms);
      |                                                                                 ^~~~~
      |                                                                                 |
      |                                                                                 long int *
/usr/include/librdkafka/rdkafka.h:3317:43: note: expected ‘int64_t *’ {aka ‘long long int *’} but argument is of type ‘long int *’
 3317 |                                  int64_t *high,
      |                                  ~~~~~~~~~^~~~
...


A fix is attached.
-------------- next part --------------
Description: Fix FTBFS on 32-bit with gcc 14
Author: Adrian Bunk <bunk at debian.org>

--- libnet-kafka-perl-1.06.orig/Kafka.xs
+++ libnet-kafka-perl-1.06/Kafka.xs
@@ -418,7 +418,7 @@ krd_query_watermark_offsets(rdk, topic,
         long timeout_ms
     PREINIT:
         rd_kafka_resp_err_t err;
-        long low, high;
+        int64_t low, high;
     PPCODE:
         err = rd_kafka_query_watermark_offsets(rdk->rk, topic, partition, &low, &high, timeout_ms);
         if (err != RD_KAFKA_RESP_ERR_NO_ERROR) {


More information about the pkg-perl-maintainers mailing list