Project

General

Profile

Variables » History » Version 19

Version 18 (Eric Krausser, 01/11/2012 03:59 PM) → Version 19/20 (Eric Krausser, 01/11/2012 04:08 PM)

h1. Variables for board.mk

h2. Board definition

*SOC_VENDOR*

A valid value would be a directory name from ./socs (http://zrouter.org/projects/zrouter/repository/show/socs).

*SOC_CHIP*

A valid value would be a directory name from ./socs/${SOC_VENDOR}.

*BOARD_FLASH_TYPE*

Obsolete, don't use it.

*BOARD_FLASH_SIZE*

Physical capacity of the flash chip in bytes. Valid values are numbers, hex numbers, or numbers with trailing M or K.

e.g.:
BOARD_FLASH_SIZE=8388608
BOARD_FLASH_SIZE=0x00800000
BOARD_FLASH_SIZE=8M
BOARD_FLASH_SIZE=8192K

h2. Customize kernel

*KERNCONF_IDENT*

Usually ${TARGET_VENDOR}_${TARGET_DEVICE}

*WITH_USB*

If defined (e.g. set to WITH_USB=yes), build with kernel modules like usb, ehci, umass, etc. (see ./socs/${SOC_VENDOR}/${SOC_CHIP}/soc.mk).

*KERNCONF_MODULES_OVERRIDE*

Use this to append additional kernel modules, e.g. for some common USB stuff:
@KERNCONF_MODULES_OVERRIDE+=usb/uplcom usb/u3g usb/umodem usb/ucom cam [email protected]
or for WLAN:
@KERNCONF_MODULES_OVERRIDE+=wlan_xauth wlan_wep wlan_tkip wlan_acl wlan_amrr wlan_ccmp [email protected]

h2. Customize world

*WORLD_SUBDIRS_ZROUTER*

?? Additional utilities, e.g. WORLD_SUBDIRS_ZROUTER+=target/sbin/upgrade

*WORLD_BUILD_ENV_EXTRA*

Allow to add extra flags for buildworld.

*TARGET_PROFILES*

TARGET_PROFILES+=SMALL_
#TARGET_PROFILES+=SMALL_ mpd ssh shttpd dlink.ua.web hostap dhcp nfs_client # mono # racoon

h2. Firmware image options

*FIRMWARE_IMAGE_SIZE_MAX*

The Image must not be bigger than the geom_map 'upgrade' partition (see [[Partition_layout]]), but other limitations can apply. For example NQ-900 has 32M of RAM and 16M of flash, but it is hard to download 16M image when you have only 32M of RAM.

e.g. FIRMWARE_IMAGE_SIZE_MAX=0x007a0000

*KERNEL_COMPRESSION*

KERNEL_COMPRESSION=oldlzma
KERNEL_COMPRESSION_TYPE=oldlzma
UBOOT_KERNEL_COMPRESSION_TYPE=lzma
MKULZMA_BLOCKSIZE=65536

*PACKING_KERNEL_IMAGE*

A converter chain to use on the built FreeBSD kernel.

e.g. PACKING_KERNEL_IMAGE?=kernel.strip.oldlzma.uboot.sync

Available converters for kernel:
* _bz2_ to compress the kernel with bzip2 (depends on bootloader if he can decompress in the given format)
* _gz_ to compress the kernel with gzip (depends on bootloader if he can decompress in the given format)
* _kbin_ will do "objcopy -O binary ..." on the ELF-kernel, the result is a smaller binary kernel (without ELF header)
* _oldlzma_ to compress the kernel with old release of lzma (depends on bootloader if he can decompress in the given format)
* _strip_ will strip symbols from the kernel to save space
* _sync_ pad kernel with zeros to block size (like dd(1) conv=sync option do). Example: if kernel size is 127k and flash block size is 64k, it become 128k with 1k zeros in it.
* _uboot_ pack kernel with U-Boot mkimage (uboot_mkimage) tool
* _xz_ to compress the kernel with xz (depends on bootloader if he can decompress in the given format)

*PACKING_ROOTFS_IMAGE*

A converter chain to use on the built rootfs file system.

e.g. PACKING_ROOTFS_IMAGE?=rootfs_clean.iso.ulzma

Available converters for rootfs:
* _iso_ pack rootfs as iso9660 file system
* _ffs_ pack rootfs as FFS/UFS file system
* _tar_ pack rootfs with regular tar(1) utility
* _bz2_, _gz_, _xz_, _sync_ can be also applied if required (see PACKING_KERNEL_IMAGE)

*NEW_IMAGE_TYPE*

Valid values:
* zimage (for regular uboot images, see [[zimage]])
* ubntimage (for Ubiquty boards)
* trximage
* tplink_image (for some TP-Link boards with 'special' uboot)
* split_kernel_rootfs

e.g. NEW_IMAGE_TYPE=zimage

h1. Variables for profile.mk

*WORLD_SUBDIRS*

*WORLD_SUBDIRS_BIN*

A shortcut that add to WORLD_SUBDIRS each bin/${item}

*WORLD_SUBDIRS_SBIN*

A shortcut that add to WORLD_SUBDIRS each sbin/${item}

*WORLD_SUBDIRS_USR_SBIN*

A shortcut that add to WORLD_SUBDIRS each usr.sbin/${item}

*WORLD_SUBDIRS_USR_BIN*

A shortcut that add to WORLD_SUBDIRS each usr.bin/${item}

*WORLD_SUBDIRS_LIB*

A shortcut that add to WORLD_SUBDIRS each lib/${item}