mirror of
https://github.com/opnsense/src.git
synced 2026-06-11 01:30:30 -04:00
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. Reviewed by: imp, jhb MFC after: 1 month Sponsored by: Turing Robotic Industries Inc. Differential Revision: https://reviews.freebsd.org/D14284
This commit is contained in:
parent
219ff59ce2
commit
b8283138cd
1 changed files with 2 additions and 2 deletions
|
|
@ -243,14 +243,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(PREFIX_SYMS)
|
||||
${AWK} -v prefix=${PREFIX_SYMS} -f ${SYSDIR}/conf/kmod_syms_prefix.awk \
|
||||
${.TARGET} /dev/null | xargs -J% ${OBJCOPY} % ${.TARGET}
|
||||
|
|
|
|||
Loading…
Reference in a new issue