Project

General

Profile

kernconfdir.diff

Oleksandr Rybalko, 08/17/2011 10:37 PM

View differences:

Makefile Wed May 25 10:53:12 2011 -0300
50 50

51 51

52 52
# Generate kernel config file
53
KERNEL_HINTS_FILE?=${KERNELCONFDIR}/${TARGET_VENDOR}_${TARGET_DEVICE}.hints
54
KERNEL_CONFIG_FILE?=${KERNELCONFDIR}/${TARGET_VENDOR}_${TARGET_DEVICE}
53
KERNEL_CONFIG_NAME=${TARGET_VENDOR}_${TARGET_DEVICE}
54
KERNEL_HINTS_FILE?=${KERNELCONFDIR}/${KERNEL_CONFIG_NAME}.hints
55
KERNEL_CONFIG_FILE?=${KERNELCONFDIR}/${KERNEL_CONFIG_NAME}
55 56

56 57
kernelconfig:	${TARGET_SOCDIR}/${SOC_KERNCONF} ${KERNELCONFDIR}
57 58
	echo "# Kernel config for ${SOC_CHIP} on ${TARGET_VENDOR} ${TARGET_DEVICE} board" > ${KERNEL_CONFIG_FILE}
......
116 117
${ZROUTER_OBJ}/tmp/${TARGET}.${TARGET_ARCH}/${FREEBSD_SRC_TREE}/tmp/usr/bin/cc:	kernel-toolchain
117 118

118 119
kernel-build:	kernelconfig kernelhints ${ZROUTER_OBJ}/tmp/${TARGET}.${TARGET_ARCH}/${FREEBSD_SRC_TREE}/tmp/usr/bin/cc
119
	MAKEOBJDIRPREFIX=${ZROUTER_OBJ}/tmp/ ${MAKE} ${_KERNEL_BUILD_ENV} -C ${FREEBSD_SRC_TREE} KERNCONF=${KERNEL_CONFIG_FILE} buildkernel
120
	MAKEOBJDIRPREFIX=${ZROUTER_OBJ}/tmp/ ${MAKE} ${_KERNEL_BUILD_ENV} -C ${FREEBSD_SRC_TREE} KERNCONFDIR=${KERNELCONFDIR} KERNCONF=${KERNEL_CONFIG_NAME} buildkernel
120 121

121 122
#XXX_BEGIN Only for testing
122 123
KMODOWN!=id -u -n
......
415 416
${KERNELDESTDIR}/boot/kernel/kernel:	${ZROUTER_OBJ}/tmp/${TARGET}.${TARGET_ARCH}/${FREEBSD_SRC_TREE}/sys/${KERNEL_CONFIG_FILE}/kernel kernel-install-dir
416 417
	@echo "++++++++++++++ Making $@ ++++++++++++++"
417 418
.if !empty(KERNELDESTDIR)
418
	MAKEOBJDIRPREFIX=${ZROUTER_OBJ}/tmp/ ${MAKE} ${_KERNEL_BUILD_ENV} -C ${FREEBSD_SRC_TREE} DESTDIR=${KERNELDESTDIR} KERNCONF=${KERNEL_CONFIG_FILE} installkernel
419
	MAKEOBJDIRPREFIX=${ZROUTER_OBJ}/tmp/ ${MAKE} ${_KERNEL_BUILD_ENV} -C ${FREEBSD_SRC_TREE} DESTDIR=${KERNELDESTDIR} KERNCONFDIR=${KERNELCONFDIR} KERNCONF=${KERNEL_CONFIG_NAME} installkernel
419 420
.else
420 421
.error "KERNELDESTDIR must be set for kernel-install, since we always do cross-build"
421 422
.endif