Author: emaste
Date: Fri Mar 30 01:19:53 2018
New Revision: 331751
URL: https://svnweb.freebsd.org/changeset/base/331751

Log:
  MFC r329373: Correct module symbol export handling
  
  EXPORT_SYMS can be set to YES, NO, a list of symbols to export from a
  module, or to a filename containing such a list.  For the case that it
  is set to a symbol list, replace spaces in the list with newlines, so
  the created file is in the format expected by kmod_syms.awk.
  
  Sponsored by: Turing Robotic Industries Inc.

Modified:
  stable/11/sys/conf/kmod.mk
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/conf/kmod.mk
==============================================================================
--- stable/11/sys/conf/kmod.mk  Fri Mar 30 00:10:39 2018        (r331750)
+++ stable/11/sys/conf/kmod.mk  Fri Mar 30 01:19:53 2018        (r331751)
@@ -238,14 +238,14 @@ ${FULLPROG}: ${OBJS}
 .if ${EXPORT_SYMS} == NO
        :> export_syms
 .elif !exists(${.CURDIR}/${EXPORT_SYMS})
-       echo ${EXPORT_SYMS} > export_syms
+       echo -n "${EXPORT_SYMS:@s@$s${.newline}@}" > export_syms
 .else
        grep -v '^#' < ${EXPORT_SYMS} > export_syms
 .endif
        ${AWK} -f ${SYSDIR}/conf/kmod_syms.awk ${.TARGET} \
            export_syms | xargs -J% ${OBJCOPY} % ${.TARGET}
 .endif
-.endif
+.endif # defined(EXPORT_SYMS)
 .if !defined(DEBUG_FLAGS) && ${__KLD_SHARED} == no
        ${OBJCOPY} --strip-debug ${.TARGET}
 .endif
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to