krb5: Install profile.h again

Commit 1876de606e exposed missing symbols that the port security/krb5
installed that the base system did not install. Part of the solution
was to make libprofile.so private (not libprofile.a) just as the port
does, Red Hat Enterprise Linux does, and as installing MIT KRB5 by hand
does. The actual fix for this was to put symbols and their corresponding
functions into the correct librarires, i.e. libkrb5.so and othes, just
as the port, Red Hat, and manually installed via tarball do.

Unfortunately INTERNALLIB disables the include of bsd.incs.mk and the
install of header files. This is still needed to install profile.h into
/usr/include (just as the port installs it into ${LOCALBASE}/include
and RHEL installs it in /usr/include). This commit fixes this by
installing profile.h into /usr/include from the krb5/include Makfile.

Reported by:	fluffy
Tested by:	fluffy
Reviewed by:	fluffy
Fixes:		1876de606e
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D58286
This commit is contained in:
Cy Schubert committed 2026-07-27 07:01:21 -07:00
1 parent b1f3726f7a
commit cf3eeeb75c
3 files changed
+38 -29

No files matched your search

+11 -3
View File
@@ -19,12 +19,15 @@ INCSDIR= ${INCLUDEDIR}
.PATH: ${KRB5_DIR}/include
SRCS= ${GEN}
INCS= gssapi.h \
kdb.h \
krad.h \
krb5.h
krb5.h \
profile.h
CLEANFILES= osconf.new
CLEANFILES= osconf.new profile.h
# XXX The output of this needs to be verified against the osconf.h I created
# It is only used to verify osconf.h has not changed
@@ -34,8 +37,13 @@ osconf.h:
rebuild-error-tables: ${K5_ET_HEADERS}
.include "${KRB5_SRCTOP}/util/profile/Makefile.profile"
.PHONY: rebuild-error-tables osconf.h
.PATH: ${KRB5_DIR}/include/krb5
.SUFFIXES: .et
.PATH: ${KRB5_DIR}/include/krb5 \
${KRB5_DIR}/util/profile
.include <bsd.prog.mk>
+1 -26
View File
@@ -36,32 +36,7 @@ CFLAGS+=${DEFINES} \
-I${KRB5_DIR}/include \
-I${.OBJDIR}
GEN= profile.h ${GEN_PROF_ERR_C} ${GEN_PROF_ERR_H}
GEN_PROF_ERR= prof_err.et
GEN_PROF_ERR_C= ${GEN_PROF_ERR:S/.et$/.c/}
GEN_PROF_ERR_H= ${GEN_PROF_ERR:S/.et$/.h/}
${GEN_PROF_ERR:[2..-1]}: .NOMETA
CLEANFILES= et-h-prof_err.et et-h-prof_err.c et-h-prof_err.h \
${GEN}
.include "${KRB5_SRCTOP}/Makefile.et"
${GEN_PROF_ERR_H}: ${GEN_PROF_ERR}
rm -f et-h-${.PREFIX}.et et-h-${.PREFIX}.c et-h-${.PREFIX}.h
cp ${.ALLSRC} et-h-${.PREFIX}.et
${COMPILE_ET} et-h-${.PREFIX}.et
mv et-h-${.PREFIX}.h ${.PREFIX}.h
rm -f et-h-${.PREFIX}.et et-h-${.PREFIX}.h
${GEN_PROF_ERR_C}: ${GEN_PROF_ERR}
rm -f et-c-${.PREFIX}.et et-c-${.PREFIX}.c et-c-${.PREFIX}.h
cp ${.ALLSRC} et-c-${.PREFIX}.et
${COMPILE_ET} et-c-${.PREFIX}.et
mv et-c-${.PREFIX}.c ${.PREFIX}.c
rm -f et-c-${.PREFIX}.et et-c-${.PREFIX}.c
profile.h: profile.hin prof_err.h
cat ${.ALLSRC} > ${.TARGET}
.include "Makefile.profile"
prof_file.c: profile.h
+26
View File
@@ -0,0 +1,26 @@
GEN= profile.h ${GEN_PROF_ERR_C} ${GEN_PROF_ERR_H}
GEN_PROF_ERR= prof_err.et
GEN_PROF_ERR_C= ${GEN_PROF_ERR:S/.et$/.c/}
GEN_PROF_ERR_H= ${GEN_PROF_ERR:S/.et$/.h/}
${GEN_PROF_ERR:[2..-1]}: .NOMETA
CLEANFILES+= et-h-prof_err.et et-h-prof_err.c et-h-prof_err.h \
${GEN}
.include "${KRB5_SRCTOP}/Makefile.et"
${GEN_PROF_ERR_H}: ${GEN_PROF_ERR}
rm -f et-h-${.PREFIX}.et et-h-${.PREFIX}.c et-h-${.PREFIX}.h
cp ${.ALLSRC} et-h-${.PREFIX}.et
${COMPILE_ET} et-h-${.PREFIX}.et
mv et-h-${.PREFIX}.h ${.PREFIX}.h
rm -f et-h-${.PREFIX}.et et-h-${.PREFIX}.h
${GEN_PROF_ERR_C}: ${GEN_PROF_ERR}
rm -f et-c-${.PREFIX}.et et-c-${.PREFIX}.c et-c-${.PREFIX}.h
cp ${.ALLSRC} et-c-${.PREFIX}.et
${COMPILE_ET} et-c-${.PREFIX}.et
mv et-c-${.PREFIX}.c ${.PREFIX}.c
rm -f et-c-${.PREFIX}.et et-c-${.PREFIX}.c
profile.h: profile.hin prof_err.h
cat ${.ALLSRC} > ${.TARGET}