mirror of
https://github.com/opnsense/src.git
synced 2026-06-04 22:32:43 -04:00
stand: move libgeliboot into libsa.
Reduce by 1 the number of crazy libraries we need in stand by moving geli into libsa (where architecturally it belonged all along). This just moves things around without any code changes.
This commit is contained in:
parent
ff150bea29
commit
62bd02cee5
15 changed files with 21 additions and 37 deletions
|
|
@ -21,8 +21,6 @@ S.${MK_ZFS}+= zfs
|
|||
S.yes+= defaults
|
||||
S.yes+= man
|
||||
|
||||
S.${MK_LOADER_GELI}+= geli
|
||||
|
||||
.include <bsd.arch.inc.mk>
|
||||
|
||||
S.${MK_EFI}+= efi
|
||||
|
|
|
|||
|
|
@ -67,8 +67,7 @@ MK_LOADER_GELI=yes
|
|||
.endif
|
||||
.if ${MK_LOADER_GELI} == "yes"
|
||||
CFLAGS+= -DLOADER_GELI_SUPPORT
|
||||
CFLAGS+= -I${BOOTSRC}/geli
|
||||
LIBGELIBOOT= ${BOOTOBJ}/geli/libgeliboot.a
|
||||
CFLAGS+= -I${SASRC}/geli
|
||||
.endif # MK_LOADER_GELI
|
||||
.endif # HAVE_GELI
|
||||
|
||||
|
|
|
|||
|
|
@ -1,15 +0,0 @@
|
|||
# $FreeBSD$
|
||||
# Autogenerated - do NOT edit!
|
||||
|
||||
DIRDEPS = \
|
||||
include \
|
||||
include/xlocale \
|
||||
lib/libmd \
|
||||
secure/lib/libcrypto \
|
||||
|
||||
|
||||
.include <dirdeps.mk>
|
||||
|
||||
.if ${DEP_RELDIR} == ${_DEP_RELDIR}
|
||||
# local dependencies - needed for -jN in clean tree
|
||||
.endif
|
||||
|
|
@ -64,7 +64,7 @@ gptboot.bin: gptboot.out
|
|||
${OBJCOPY} -S -O binary gptboot.out ${.TARGET}
|
||||
|
||||
gptboot.out: ${BTXCRT} gptboot.o sio.o crc32.o drv.o cons.o ${OPENCRYPTO_XTS}
|
||||
${LD} ${LD_FLAGS} -Ttext ${ORG2} -o ${.TARGET} ${.ALLSRC} ${LIBGELIBOOT} ${LIBSA32}
|
||||
${LD} ${LD_FLAGS} -Ttext ${ORG2} -o ${.TARGET} ${.ALLSRC} ${LIBSA32}
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ gptzfsboot.bin: gptzfsboot.out
|
|||
|
||||
gptzfsboot.out: ${BTXCRT} zfsboot.o sio.o gpt.o drv.o cons.o \
|
||||
${OPENCRYPTO_XTS}
|
||||
${LD} ${LD_FLAGS} -Ttext ${ORG2} -o ${.TARGET} ${.ALLSRC} ${LIBGELIBOOT} ${LIBZFSBOOT} ${LIBSA32}
|
||||
${LD} ${LD_FLAGS} -Ttext ${ORG2} -o ${.TARGET} ${.ALLSRC} ${LIBZFSBOOT} ${LIBSA32}
|
||||
|
||||
zfsboot.o: ${ZFSSRC}/zfsimpl.c
|
||||
|
||||
|
|
|
|||
|
|
@ -66,6 +66,6 @@ isoboot.bin: isoboot.out
|
|||
${OBJCOPY} -S -O binary isoboot.out ${.TARGET}
|
||||
|
||||
isoboot.out: ${BTXCRT} isoboot.o sio.o crc32.o drv.o cons.o ${OPENCRYPTO_XTS}
|
||||
${LD} ${LD_FLAGS} -Ttext ${ORG2} -o ${.TARGET} ${.ALLSRC} ${LIBGELIBOOT} ${LIBSA32}
|
||||
${LD} ${LD_FLAGS} -Ttext ${ORG2} -o ${.TARGET} ${.ALLSRC} ${LIBSA32}
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
|
|
|||
|
|
@ -71,8 +71,8 @@ FILESMODE_${LOADER}= ${BINMODE} -b
|
|||
# XXX crt0.o needs to be first for pxeboot(8) to work
|
||||
OBJS= ${BTXCRT}
|
||||
|
||||
DPADD= ${LDR_INTERP32} ${LIBFIREWIRE} ${LIBZFSBOOT} ${LIBI386} ${LIBGELIBOOT} ${LIBSA32}
|
||||
LDADD= ${LDR_INTERP32} ${LIBFIREWIRE} ${LIBZFSBOOT} ${LIBI386} ${LIBGELIBOOT} ${LIBSA32}
|
||||
DPADD= ${LDR_INTERP32} ${LIBFIREWIRE} ${LIBZFSBOOT} ${LIBI386} ${LIBSA32}
|
||||
LDADD= ${LDR_INTERP32} ${LIBFIREWIRE} ${LIBZFSBOOT} ${LIBI386} ${LIBSA32}
|
||||
|
||||
.if ${MACHINE_CPUARCH} == "amd64"
|
||||
CFLAGS+= -DLOADER_PREFER_AMD64
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ zfsboot.bin: zfsboot.out
|
|||
${OBJCOPY} -S -O binary zfsboot.out ${.TARGET}
|
||||
|
||||
zfsboot.out: ${BTXCRT} zfsboot.o sio.o drv.o cons.o
|
||||
${LD} ${LD_FLAGS} -Ttext ${ORG2} -o ${.TARGET} ${.ALLSRC} ${LIBZFSBOOT} ${LIBGELIBOOT} ${LIBSA32}
|
||||
${LD} ${LD_FLAGS} -Ttext ${ORG2} -o ${.TARGET} ${.ALLSRC} ${LIBZFSBOOT} ${LIBSA32}
|
||||
|
||||
SRCS= zfsboot.c
|
||||
|
||||
|
|
|
|||
|
|
@ -151,4 +151,9 @@ CFLAGS.bzipfs.c+= -I${SRCTOP}/contrib/bzip2
|
|||
.PATH: ${SYSDIR}/libkern
|
||||
SRCS+= explicit_bzero.c
|
||||
|
||||
# Maybe GELI
|
||||
.if ${MK_LOADER_GELI} == "yes"
|
||||
.include "${SASRC}/geli/Makefile.inc"
|
||||
.endif
|
||||
|
||||
.include <bsd.lib.mk>
|
||||
|
|
|
|||
|
|
@ -1,11 +1,9 @@
|
|||
# $FreeBSD$
|
||||
# libgeliboot
|
||||
# Extra stuff for GELI
|
||||
|
||||
DO32=1
|
||||
.PATH: ${SASRC}/geli
|
||||
|
||||
.include <bsd.init.mk>
|
||||
|
||||
LIB= geliboot
|
||||
CFLAGS+= -I${LDRSRC}
|
||||
|
||||
# Our password input method
|
||||
SRCS+= pwgets.c
|
||||
|
|
@ -21,10 +19,11 @@ SRCS+= md5c.c
|
|||
|
||||
# AES implementation from sys/crypto
|
||||
.PATH: ${SYSDIR}/crypto/rijndael
|
||||
CFLAGS+= -I${LDRSRC}
|
||||
# Remove asserts
|
||||
CFLAGS+= -DNDEBUG
|
||||
SRCS+= rijndael-alg-fst.c rijndael-api-fst.c rijndael-api.c
|
||||
.for i in rijndael-alg-fst.c rijndael-api-fst.c rijndael-api.c
|
||||
# Remove asserts XXX BAD
|
||||
CFLAGS.${i}+= -DNDEBUG
|
||||
SRCS+= ${i}
|
||||
.endfor
|
||||
|
||||
# local GELI Implementation
|
||||
.PATH: ${SYSDIR}/geom/eli
|
||||
|
|
@ -33,5 +32,3 @@ SRCS+= geliboot_crypto.c g_eli_hmac.c g_eli_key.c g_eli_key_cache.c pkcs5v2.c
|
|||
# aes
|
||||
.PATH: ${SYSDIR}/opencrypto
|
||||
SRCS+= xform_aes_xts.c
|
||||
|
||||
.include <bsd.lib.mk>
|
||||
|
|
@ -71,7 +71,7 @@ geliboot_crypt(u_int algo, int enc, u_char *data, size_t datasize,
|
|||
}
|
||||
if (datasize != (blks / 8)) {
|
||||
printf("Failed to decrypt the entire input: "
|
||||
"%u != %u\n", blks, datasize);
|
||||
"%u != %zu\n", blks, datasize);
|
||||
return (1);
|
||||
}
|
||||
break;
|
||||
Loading…
Reference in a new issue