Skip to content

Commit 88ecd1e

Browse files
authored
Merge pull request syslog-ng#4924 from MrAnno/macos-build-fixes
Minor build-related fixes
2 parents 157ee5f + 721eda3 commit 88ecd1e

25 files changed

+60
-37
lines changed

Makefile.am

+1-1
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ TEST_LDADD = $(LIBTEST_LIBS) $(CRITERION_LIBS) \
132132
$(top_builddir)/lib/libsyslog-ng.la \
133133
$(TOOL_DEPS_LIBS)
134134

135-
test_ldflags = -no-install $(NO_PIE_LDFLAG)
135+
test_ldflags = $(TEST_NO_INSTALL_FLAG) $(NO_PIE_LDFLAG)
136136

137137
PREOPEN_SYSLOGFORMAT = -dlpreopen ${top_builddir}/modules/syslogformat/libsyslogformat.la
138138
PREOPEN_BASICFUNCS = -dlpreopen ${top_builddir}/modules/basicfuncs/libbasicfuncs.la

configure.ac

+16-4
Original file line numberDiff line numberDiff line change
@@ -507,13 +507,15 @@ AC_PROG_CXX([$CPP_COMPILER])
507507

508508
if test "x$enable_cpp" = "xyes"; then
509509
AX_CXX_COMPILE_STDCXX(11,, mandatory)
510+
AX_CXX_COMPILE_STDCXX(17,, optional)
510511
elif test "x$enable_cpp" = "xauto"; then
511512
AX_CXX_COMPILE_STDCXX(11,, optional)
512513
if test "x$HAVE_CXX11" = "x1"; then
513514
enable_cpp=yes
514515
else
515516
enable_cpp=no
516517
fi
518+
AX_CXX_COMPILE_STDCXX(17,, optional)
517519
fi
518520

519521
dnl ***************************************************************************
@@ -646,6 +648,9 @@ dnl User supplied CFLAGS come last
646648
CFLAGS="${CFLAGS_ADD} ${ac_cv_env_CFLAGS_value}"
647649
CXXFLAGS="${CXXFLAGS_ADD} ${ac_cv_env_CXXFLAGS_value}"
648650

651+
TEST_NO_INSTALL_FLAG="-no-install"
652+
AC_SUBST(TEST_NO_INSTALL_FLAG)
653+
649654
AC_SYS_LARGEFILE
650655

651656
# FIXME: skip tests on unsupported platforms/architectures...
@@ -675,6 +680,7 @@ case "$ostype" in
675680
;;
676681
Darwin)
677682
MODULE_LDFLAGS="-avoid-version -dylib"
683+
TEST_NO_INSTALL_FLAG="-no-fast-install"
678684
# This flag might be a security issue, do not use in production code, unfortunately we still need it for criterion tests and the current mocking solution
679685
if test "x$enable_tests" = "xyes"; then
680686
LDFLAGS="$LDFLAGS -Wl,-flat_namespace"
@@ -724,8 +730,10 @@ dnl Check for --whole-archive flag
724730
dnl ***************************************************************************
725731

726732
if test $ostype = "Darwin"; then
733+
# -all_load loads all members of static archive libraries, it can't be selectively disabled (do not use -noall_load)
734+
# use -force_load for each static library if mixed linking needs to be supported on macOS
727735
WHOLE_ARCHIVE_OPT="-all_load"
728-
NO_WHOLE_ARCHIVE_OPT="-noall_load"
736+
NO_WHOLE_ARCHIVE_OPT=""
729737
else
730738
WHOLE_ARCHIVE_OPT="--whole-archive"
731739
NO_WHOLE_ARCHIVE_OPT="--no-whole-archive"
@@ -1103,9 +1111,12 @@ if test "x$enable_geoip2" = "xyes" || test "x$enable_geoip2" = "xauto"; then
11031111
AC_MSG_RESULT([yes (MAXMINDDB_LIBS set, will use that.)])
11041112
with_maxminddb="yes"
11051113
else
1106-
AC_MSG_CHECKING([for MAXMINDDB])
1107-
AC_CHECK_LIB(maxminddb, MMDB_open, MAXMINDDB_LIBS="-lmaxminddb"; with_maxminddb="yes", with_maxminddb="no")
1108-
AC_SUBST(MAXMINDDB_LIBS)
1114+
PKG_CHECK_MODULES(MAXMINDDB, libmaxminddb, [with_maxminddb="yes"], [with_maxminddb="no"])
1115+
if test "x$with_maxminddb" = "xno"; then
1116+
AC_MSG_CHECKING([for MAXMINDDB])
1117+
AC_CHECK_LIB(maxminddb, MMDB_open, MAXMINDDB_LIBS="-lmaxminddb"; with_maxminddb="yes", with_maxminddb="no")
1118+
AC_SUBST(MAXMINDDB_LIBS)
1119+
fi
11091120
fi
11101121

11111122
if test "x$with_maxminddb" = "xno" && test "x$enable_geoip2" = "xyes"; then
@@ -1211,6 +1222,7 @@ fi
12111222

12121223
if test -n "$LIBNET_CONFIG" -a -x "$LIBNET_CONFIG"; then
12131224
LIBNET_CFLAGS="`$LIBNET_CONFIG --defines`"
1225+
LIBNET_CFLAGS="$LIBNET_CFLAGS `$LIBNET_CONFIG --cflags`"
12141226
LIBNET_LIBS="`$LIBNET_CONFIG --libs`"
12151227
AC_MSG_RESULT(yes)
12161228
dnl libnet-config does not provide the _DEFAULT_SOURCE define, that can cause warning during build

lib/debugger/debugger.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,7 @@ debugger_perform_tracing(Debugger *self, LogPipe *pipe_, LogMessage *msg)
411411

412412
long diff = prev_ts->tv_sec == 0 ? 0 : timespec_diff_nsec(&ts, prev_ts);
413413
printf("[%"G_GINT64_FORMAT".%09"G_GINT64_FORMAT" +%ld] Tracing %s\n",
414-
ts.tv_sec, ts.tv_nsec, diff,
414+
(gint64)ts.tv_sec, (gint64)ts.tv_nsec, diff,
415415
log_expr_node_format_location(pipe_->expr_node, buf, sizeof(buf)));
416416
*prev_ts = ts;
417417
return TRUE;

lib/logproto/tests/test_findeom.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@
2121
*
2222
*/
2323

24-
#include <criterion/parameterized.h>
2524
#include <criterion/criterion.h>
25+
#include <criterion/parameterized.h>
2626

2727
#include "logproto/logproto-server.h"
2828
#include "logmsg/logmsg.h"

lib/tests/test_msgparse.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ test_log_messages_can_be_parsed(struct msgparse_params *param)
159159
{
160160
if (param->expected_stamp_sec != 1)
161161
cr_assert_eq(parsed_timestamp->ut_sec, param->expected_stamp_sec,
162-
"Unexpected timestamp, value=%ld, expected=%ld, msg=%s",
162+
"Unexpected timestamp, value=%"G_GINT64_FORMAT", expected=%lu, msg=%s",
163163
parsed_timestamp->ut_sec, param->expected_stamp_sec, param->msg);
164164

165165
cr_assert_eq(parsed_timestamp->ut_usec, param->expected_stamp_usec, "Unexpected microseconds");

lib/timeutils/wallclocktime.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -687,7 +687,7 @@ wall_clock_time_strptime(WallClockTime *wct, const gchar *format, const gchar *i
687687
{
688688
wct->tm.tm_isdst = i;
689689
wct->wct_gmtoff = -cached_get_system_tzofs() + wct->tm.tm_isdst*3600;
690-
wct->wct_zone = system_tznames[i];
690+
wct->wct_zone = __UNCONST(system_tznames[i]);
691691
bp = ep;
692692
continue;
693693
}

libtest/stopwatch.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,5 +58,5 @@ stop_stopwatch_and_display_result(gint iterations, const gchar *message_template
5858
va_end(args);
5959

6060
printf("; %.2f iterations/sec", iterations * 1e6 / diff);
61-
printf(", runtime=%lu.%06lus\n", diff / 1000000, diff % 1000000);
61+
printf(", runtime=%"G_GUINT64_FORMAT".%06"G_GUINT64_FORMAT"s\n", diff / 1000000, diff % 1000000);
6262
}

modules/afsocket/afsocket-source.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
#include <sys/types.h>
3838
#include <sys/socket.h>
3939

40-
#if SYSLOG_NG_HAVE_LINUX_SOCK_DIAG_H
40+
#ifdef SYSLOG_NG_HAVE_LINUX_SOCK_DIAG_H
4141
#include <linux/sock_diag.h>
4242
#endif
4343

modules/afsocket/socket-options-inet.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,6 @@ socket_options_inet_setup_socket(SocketOptions *s, gint fd, GSockAddr *addr, AFS
131131
{
132132
SocketOptionsInet *self = (SocketOptionsInet *) s;
133133
gint off = 0;
134-
gint on = 1;
135134

136135
if (!socket_options_setup_socket_method(s, fd, addr, dir))
137136
return FALSE;
@@ -177,6 +176,7 @@ socket_options_inet_setup_socket(SocketOptions *s, gint fd, GSockAddr *addr, AFS
177176
if (self->ip_freebind && (dir & AFSOCKET_DIR_RECV))
178177
{
179178
#ifdef IP_FREEBIND
179+
gint on = 1;
180180
setsockopt(fd, SOL_IP, IP_FREEBIND, &on, sizeof(on));
181181
#else
182182
msg_error("ip-freebind() is set but no IP_FREEBIND setsockopt on this platform");
@@ -215,6 +215,7 @@ socket_options_inet_setup_socket(SocketOptions *s, gint fd, GSockAddr *addr, AFS
215215
if (self->ip_freebind && (dir & AFSOCKET_DIR_RECV))
216216
{
217217
#ifdef IP_FREEBIND
218+
gint on = 1;
218219
/* NOTE: there's no separate IP_FREEBIND option for IPV6, it re-uses the IPv4 one */
219220
setsockopt(fd, SOL_IP, IP_FREEBIND, &on, sizeof(on));
220221
#else

modules/diskq/qdisk.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,7 @@ _maybe_truncate_file(QDisk *self, gint64 expected_size)
458458
evt_tag_int("fd", self->fd));
459459
}
460460

461-
#if !SYSLOG_NG_HAVE_POSIX_FALLOCATE
461+
#ifndef SYSLOG_NG_HAVE_POSIX_FALLOCATE
462462
static gint
463463
_compat_preallocate(int fd, off_t offset, off_t len)
464464
{
@@ -494,7 +494,7 @@ _preallocate_qdisk_file(QDisk *self, off_t size)
494494

495495
gint result;
496496

497-
#if SYSLOG_NG_HAVE_POSIX_FALLOCATE
497+
#ifdef SYSLOG_NG_HAVE_POSIX_FALLOCATE
498498
result = posix_fallocate(self->fd, QDISK_RESERVED_SPACE, size - QDISK_RESERVED_SPACE);
499499
#else
500500
result = _compat_preallocate(self->fd, QDISK_RESERVED_SPACE, size - QDISK_RESERVED_SPACE);

modules/diskq/tests/test_diskq_truncate.c

+6-3
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,8 @@ _assert_diskq_actual_file_size_with_stored(LogQueue *q)
139139

140140
gint64 actual_file_size = _get_file_size(q);
141141
cr_assert_eq(qdisk->cached_file_size, actual_file_size,
142-
"File size does not match with stored size; Actual file size: %ld, Expected file size: %ld\n", actual_file_size,
142+
"File size does not match with stored size; Actual file size: %"G_GINT64_FORMAT", Expected file size: %"G_GINT64_FORMAT"\n",
143+
actual_file_size,
143144
qdisk->cached_file_size);
144145
}
145146

@@ -279,12 +280,14 @@ Test(diskq_truncate, test_diskq_truncate_on_push)
279280
feed_some_messages(q, write_wraps_message_number);
280281
// file size can even grow, if not the whole capacity_bytes is filled (i.e. capacity_bytes is not an integer multiple of one message size)
281282
cr_assert(_get_file_size(q) >= file_size_full,
282-
"Unexpected disk-queue truncate during push! size:%ld expected:%ld", _get_file_size(q), file_size_full);
283+
"Unexpected disk-queue truncate during push! size:%"G_GINT64_FORMAT" expected:%"G_GINT64_FORMAT, _get_file_size(q),
284+
file_size_full);
283285

284286
// 4. wrap around read pointer. Truncate only happens if read < write < file_size
285287
send_some_messages(q, read_wraps_message_number, TRUE);
286288
cr_assert(_get_file_size(q) >= file_size_full,
287-
"Unexpected disk-queue truncate while read wrapped! size:%ld expected:%ld", _get_file_size(q), file_size_full);
289+
"Unexpected disk-queue truncate while read wrapped! size:%"G_GINT64_FORMAT" expected:%"G_GINT64_FORMAT,
290+
_get_file_size(q), file_size_full);
288291

289292
// 5. push some messages to trigger truncate after push
290293
feed_some_messages(q, trigger_truncate_message_number);

modules/diskq/tests/test_qdisk.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -419,10 +419,10 @@ static void
419419
_assert_backlog_and_write_head_pos(QDisk *qdisk, gint64 backlog_head_pos, gint64 write_head_pos)
420420
{
421421
cr_assert_eq(qdisk_get_backlog_head(qdisk), QDISK_RESERVED_SPACE + backlog_head_pos,
422-
"Backlog head positions does not match. Expected: %ld Actual: %ld",
422+
"Backlog head positions does not match. Expected: %"G_GINT64_FORMAT" Actual: %"G_GINT64_FORMAT,
423423
QDISK_RESERVED_SPACE + backlog_head_pos, qdisk_get_backlog_head(qdisk));
424424
cr_assert_eq(qdisk_get_writer_head(qdisk), QDISK_RESERVED_SPACE + write_head_pos,
425-
"Write head positions does not match. Expected: %ld Actual: %ld",
425+
"Write head positions does not match. %"G_GINT64_FORMAT" Actual: %"G_GINT64_FORMAT,
426426
QDISK_RESERVED_SPACE + backlog_head_pos, qdisk_get_writer_head(qdisk));
427427
}
428428

modules/examples/destinations/example_destination/example_destination_worker.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ _dw_insert(LogThreadedDestWorker *s, LogMessage *msg)
3333

3434
GString *string_to_write = g_string_new("");
3535
g_string_printf(string_to_write, "thread_id=%lu message=%s\n",
36-
self->thread_id, log_msg_get_value(msg, LM_V_MESSAGE, NULL));
36+
(unsigned long) self->thread_id, log_msg_get_value(msg, LM_V_MESSAGE, NULL));
3737

3838
size_t retval = fwrite(string_to_write->str, 1, string_to_write->len, self->file);
3939
gsize string_to_write_len = string_to_write->len;

modules/geoip2/Makefile.am

+2-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ modules_geoip2_libgeoip2_plugin_la_CPPFLAGS = \
1717
-I$(top_builddir)/modules/geoip2
1818
modules_geoip2_libgeoip2_plugin_la_CFLAGS = \
1919
$(AM_CFLAGS) \
20-
$(GEOIP_CFLAGS)
20+
$(GEOIP_CFLAGS) \
21+
$(MAXMINDDB_CFLAGS)
2122
modules_geoip2_libgeoip2_plugin_la_LIBADD = \
2223
$(MODULE_DEPS_LIBS) $(MAXMINDDB_LIBS)
2324
modules_geoip2_libgeoip2_plugin_la_LDFLAGS = \

modules/geoip2/tests/Makefile.am

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ modules_geoip2_tests_TESTS = \
44

55
check_PROGRAMS += ${modules_geoip2_tests_TESTS}
66

7-
modules_geoip2_tests_test_geoip_parser_CFLAGS = $(TEST_CFLAGS) \
7+
modules_geoip2_tests_test_geoip_parser_CFLAGS = $(TEST_CFLAGS) $(MAXMINDDB_CFLAGS) \
88
-I$(top_srcdir)/modules/geoip2
99
modules_geoip2_tests_test_geoip_parser_LDADD = $(TEST_LDADD)
1010
modules_geoip2_tests_test_geoip_parser_LDFLAGS = \

modules/grpc/bigquery/Makefile.am

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ modules_grpc_bigquery_libbigquery_cpp_la_SOURCES = \
1313

1414
modules_grpc_bigquery_libbigquery_cpp_la_CXXFLAGS = \
1515
$(AM_CXXFLAGS) \
16-
$(PROTOBUF_CLFAGS) \
16+
$(PROTOBUF_CFLAGS) \
1717
$(GRPCPP_CFLAGS) \
1818
-I$(GOOGLEAPIS_PROTO_BUILDDIR) \
1919
-I$(top_srcdir)/modules/grpc \

modules/grpc/bigquery/bigquery-dest.cpp

+4-2
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ class ErrorCollector : public google::protobuf::compiler::MultiFileErrorCollecto
5454
ErrorCollector() {}
5555
~ErrorCollector() override {}
5656

57+
// override is missing for compatibility with older protobuf versions
5758
void RecordError(absl::string_view filename, int line, int column, absl::string_view message)
5859
{
5960
std::string file{filename};
@@ -64,6 +65,7 @@ class ErrorCollector : public google::protobuf::compiler::MultiFileErrorCollecto
6465
evt_tag_str("error", msg.c_str()));
6566
}
6667

68+
// override is missing for compatibility with older protobuf versions
6769
void RecordWarning(absl::string_view filename, int line, int column, absl::string_view message)
6870
{
6971
std::string file{filename};
@@ -76,12 +78,12 @@ class ErrorCollector : public google::protobuf::compiler::MultiFileErrorCollecto
7678

7779
private:
7880
/* deprecated interface */
79-
void AddError(const std::string &filename, int line, int column, const std::string &message) override
81+
void AddError(const std::string &filename, int line, int column, const std::string &message)
8082
{
8183
this->RecordError(filename, line, column, message);
8284
}
8385

84-
void AddWarning(const std::string &filename, int line, int column, const std::string &message) override
86+
void AddWarning(const std::string &filename, int line, int column, const std::string &message)
8587
{
8688
this->RecordWarning(filename, line, column, message);
8789
}

modules/grpc/loki/Makefile.am

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ modules_grpc_loki_libloki_cpp_la_SOURCES = \
1414

1515
modules_grpc_loki_libloki_cpp_la_CXXFLAGS = \
1616
$(AM_CXXFLAGS) \
17-
$(PROTOBUF_CLFAGS) \
17+
$(PROTOBUF_CFLAGS) \
1818
$(GRPCPP_CFLAGS) \
1919
-I$(LOKI_PROTO_BUILDDIR) \
2020
-I$(top_srcdir)/modules/grpc \

modules/grpc/otel/filterx/protobuf-field.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ class u64Field : public ProtobufField
159159
evt_tag_str("field", reflectors.fieldDescriptor->name().c_str()),
160160
evt_tag_long("range_min", INT64_MIN),
161161
evt_tag_long("range_max", INT64_MAX),
162-
evt_tag_printf("current", "%lu", val));
162+
evt_tag_printf("current", "%" G_GUINT64_FORMAT, val));
163163
return NULL;
164164
}
165165
return filterx_integer_new(guint64(val));

modules/grpc/otel/tests/Makefile.am

+4
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ modules_grpc_otel_tests_test_otel_protobuf_parser_DEPENDENCIES = \
1717

1818
modules_grpc_otel_tests_test_otel_protobuf_parser_CXXFLAGS = \
1919
$(TEST_CXXFLAGS) \
20+
$(PROTOBUF_CFLAGS) $(GRPCPP_CFLAGS) \
2021
-I$(OPENTELEMETRY_PROTO_BUILDDIR) \
2122
-I$(top_srcdir)/modules/grpc/otel \
2223
-I$(top_builddir)/modules/grpc/otel
@@ -35,6 +36,7 @@ modules_grpc_otel_tests_test_otel_protobuf_formatter_DEPENDENCIES = \
3536

3637
modules_grpc_otel_tests_test_otel_protobuf_formatter_CXXFLAGS = \
3738
$(TEST_CXXFLAGS) \
39+
$(PROTOBUF_CFLAGS) $(GRPCPP_CFLAGS) \
3840
-I$(OPENTELEMETRY_PROTO_BUILDDIR) \
3941
-I$(top_srcdir)/modules/grpc/otel \
4042
-I$(top_builddir)/modules/grpc/otel
@@ -53,6 +55,7 @@ modules_grpc_otel_tests_test_syslog_ng_otlp_DEPENDENCIES = \
5355

5456
modules_grpc_otel_tests_test_syslog_ng_otlp_CXXFLAGS = \
5557
$(TEST_CXXFLAGS) \
58+
$(PROTOBUF_CFLAGS) $(GRPCPP_CFLAGS) \
5659
-I$(OPENTELEMETRY_PROTO_BUILDDIR) \
5760
-I$(top_srcdir)/modules/grpc/otel \
5861
-I$(top_builddir)/modules/grpc/otel
@@ -71,6 +74,7 @@ modules_grpc_otel_tests_test_otel_filterx_DEPENDENCIES = \
7174

7275
modules_grpc_otel_tests_test_otel_filterx_CXXFLAGS = \
7376
$(TEST_CXXFLAGS) \
77+
$(PROTOBUF_CFLAGS) $(GRPCPP_CFLAGS) \
7478
-I$(OPENTELEMETRY_PROTO_BUILDDIR) \
7579
-I$(top_srcdir)/modules/grpc/otel \
7680
-I$(top_builddir)/modules/grpc/otel

modules/grpc/protos/Makefile.am

+1-1
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ modules_grpc_protos_libgrpc_protos_la_SOURCES = \
115115

116116
modules_grpc_protos_libgrpc_protos_la_CXXFLAGS = \
117117
$(AM_CXXFLAGS) \
118-
$(PROTOBUF_CLFAGS) \
118+
$(PROTOBUF_CFLAGS) \
119119
$(GRPCPP_CFLAGS) \
120120
-I$(GOOGLEAPIS_PROTO_SRCDIR) \
121121
-I$(GOOGLEAPIS_PROTO_BUILDDIR) \

modules/kafka/tests/Makefile.am

+4-4
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,15 @@ modules_kafka_tests_test_kafka_config_DEPENDENCIES = \
2323
$(top_builddir)/modules/kafka/libkafka.la
2424

2525
modules_kafka_tests_test_kafka_topic_DEPENDENCIES = \
26-
$(top_builddir)/modules/kafka/libkafka.la
26+
$(top_builddir)/modules/kafka/libkafka.la
2727

2828
modules_kafka_tests_test_kafka_props_CFLAGS = $(TEST_CFLAGS) -I$(top_srcdir)/modules/kafka
2929

30-
modules_kafka_tests_test_kafka_config_CFLAGS = $(TEST_CFLAGS) -I$(top_srcdir)/modules/kafka
30+
modules_kafka_tests_test_kafka_config_CFLAGS = $(TEST_CFLAGS) -I$(top_srcdir)/modules/kafka $(LIBRDKAFKA_CFLAGS)
3131

32-
modules_kafka_tests_test_kafka_topic_CFLAGS = $(TEST_CFLAGS) -I$(top_srcdir)/modules/kafka
32+
modules_kafka_tests_test_kafka_topic_CFLAGS = $(TEST_CFLAGS) -I$(top_srcdir)/modules/kafka $(LIBRDKAFKA_CFLAGS)
3333

34-
modules_kafka_tests_test_kafka_props_LDADD = $(TEST_LDADD)
34+
modules_kafka_tests_test_kafka_props_LDADD = $(TEST_LDADD)
3535

3636
modules_kafka_tests_test_kafka_config_LDADD = $(TEST_LDADD) $(LIBRDKAFKA_LIBS)
3737

modules/python/python-types.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -466,7 +466,7 @@ py_datetime_to_datetime(PyObject *obj, GString *dt)
466466

467467
if (!py_datetime_to_unix_time(obj, &ut))
468468
return FALSE;
469-
g_string_printf(dt, "%ld.%03d", ut.ut_sec, ut.ut_usec / 1000);
469+
g_string_printf(dt, "%"G_GINT64_FORMAT".%03"G_GUINT32_FORMAT, ut.ut_sec, ut.ut_usec / 1000);
470470
return TRUE;
471471
}
472472

@@ -493,7 +493,7 @@ py_obj_to_log_msg_value(PyObject *obj, GString *value, LogMessageValueType *type
493493
return FALSE;
494494

495495
*type = LM_VT_INTEGER;
496-
g_string_printf(value, "%ld", l);
496+
g_string_printf(value, "%"G_GINT64_FORMAT, l);
497497

498498
return TRUE;
499499
}

modules/systemd-journal/journald-subsystem.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ static GModule *journald_ext_module;
7070
typedef struct sd_journal sd_journal;
7171

7272
static GModule *
73-
_journald_module_open(char **libraries)
73+
_journald_module_open(const char *const *libraries)
7474
{
7575
GModule *module = NULL;
7676

0 commit comments

Comments
 (0)