freebsd-dev/tools/bsdbox/Makefile.base
Adrian Chadd 6b1dcfcd83 Import the first cut of "bsdbox".
This uses the existing crunchgen infrastructure to build
a series of tools designed to replace the base and networking
tools on an embedded system.

It reuses 'bsd.crunchgen.mk' to drive the actual file
creation. The rescue build system also uses this.

Unlike busybox, it doesn't include its own source - instead,
it just builds from the sources in /usr/src/ and leverages
the existing BSD framework.

Thie is still quite messy and could do with a whole lot of
cleaning up.   However it is proving to be very useful with
my current build framework, allowing me to build binary root
images that are about 30% less than simply cherrypicking files
and libraries from an installworld.
2012-01-06 00:56:31 +00:00

56 lines
1.3 KiB
Makefile

#
# This builds a variety of "base" tools, useful for an embedded
# system.
#
# $FreeBSD$
#
CRUNCH_PROGS_sbin+= dmesg sysctl init reboot
CRUNCH_PROGS_bin+= ls cat dd df cp hostname kill mkdir sleep ps ln rm hostname
CRUNCH_PROGS_usr.bin+= true false hexdump tail nc w head uname tset
CRUNCH_PROGS_usr.sbin+= gpioctl
CRUNCH_ALIAS_w= uptime
CRUNCH_ALIAS_tset= reset
CRUNCH_PROGS_usr.bin+= vmstat systat
CRUNCH_LIBS+= -ldevstat -lncursesw -lncurses -lmemstat -lkvm
CRUNCH_PROGS_usr.bin+= tar cpio
# XXX SSL ?
CRUNCH_LIBS+= -larchive -lbz2 -lz -llzma -lbsdxml -lssl -lcrypto
# Clear requires tput, and it's a shell script so it won't be crunched
CRUNCH_PROGS_usr.bin+= tput
# sh
CRUNCH_PROGS_bin+= sh
CRUNCH_ALIAS_sh= -sh
CRUNCH_SUPPRESS_LINK_-sh= 1
CRUNCH_BUILDTOOLS+= bin/sh
# chown
CRUNCH_PROGS_usr.sbin+= chown
CRUNCH_ALIAS_chown= chgrp
# Basic filesystem stuff
CRUNCH_PROGS_sbin+= mount umount
# grep
# grep doesn't yet work -adrian
CRUNCH_PROGS_usr.bin+= grep
# less/more
CRUNCH_PROGS_usr.bin+= less
CRUNCH_ALIAS_less= more
# passwd
CRUNCH_PROGS_usr.bin+= passwd
# These need to be shared, or PAM wants to include _all_ of the libraries
# at runtime.
CRUNCH_SHLIBS+= -lpam -lbsm
# gzip/gunzip
CRUNCH_PROGS_usr.bin+= gzip
CRUNCH_ALIAS_gunzip= gzip
CRUNCH_ALIAS_gzcat= gzip
CRUNCH_LIBS+= -lz -llzma -lbz2