Skip to content

Commit

Permalink
Don't install at.h when glibc header found, GitHub#409
Browse files Browse the repository at this point in the history
  • Loading branch information
rdmark committed Aug 27, 2023
1 parent 17084a2 commit 8950d69
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
6 changes: 6 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -692,6 +692,11 @@ dnl AC_COMPILE_IFELSE([
AC_MSG_RESULT([no])
])

dnl ----- Use the glibc at.h header if found -----
AC_CHECK_HEADER([netatalk/at.h], [
use_glibc_at_header=yes
])

if test "x$ac_have_atalk_addr" = "xyes"; then
AC_DEFINE(HAVE_ATALK_ADDR, 1, [set if struct at_addr is called atalk_addr])
fi
Expand Down Expand Up @@ -1320,6 +1325,7 @@ AM_CONDITIONAL(USE_BDB, test x$bdb_required = xyes)
AM_CONDITIONAL(USE_APPLETALK, test x$netatalk_cv_ddp_enabled = xyes)
AM_CONDITIONAL(HAVE_ATFUNCS, test x"$ac_neta_haveatfuncs" = x"yes")
AM_CONDITIONAL(USE_INSTALL_PRIVILEGED, test x"$install_privileged" = x"yes")
AM_CONDITIONAL(USE_GLIBC_AT_HEADER, test x$use_glibc_at_header = xyes)

dnl Enable silent Automake rules if present
m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
Expand Down
6 changes: 6 additions & 0 deletions sys/netatalk/Makefile.am
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
# Makefile.am for sys/netatalk/

# Install at.h only on systems that don't use glibc
if USE_GLIBC_AT_HEADER
pkginclude_HEADERS = aarp.h at_var.h ddp.h ddp_var.h endian.h phase2.h
noinst_HEADERS = at.h
else
pkginclude_HEADERS = aarp.h at.h at_var.h ddp.h ddp_var.h endian.h phase2.h
endif

SOURCES = aarp.c at_control.c at_proto.c ddp_input.c ddp_output.c ddp_usrreq.c

Expand Down

0 comments on commit 8950d69

Please sign in to comment.