Prerequisitessudo apt install build-essential ccache ecj fastjar file g++ gawk gettext git java-propose-classpath libelf-dev libncurses5-dev libncursesw5-dev libssl-dev python3 unzip wget python3-distutils python3-distutils-extra python3-setuptools python3-dev rsync subversion swig time xsltproc zlib1g-dev Add Interface to firewall config file fw_configure_interface $network add $device Post install scriptsAdd a post-install part in your Makefile. Once you have that, you can script anything you wish, like adding users and setting ownerships. The package for Tor has a nice example of how to do this. I have pasted the relevant part of the Tor Makefile here, which I will comment on afterwards:
define Package/tor/postinst #!/bin/sh # # check if we are on real system if [ -z "$${IPKG_INSTROOT}" ]; then # create copies of passwd and group, if we use squashfs rootfs=`mount |awk '/root/ { print $$5 }'` if [ "$$rootfs" = "squashfs" ]; then if [ -h /etc/group ]; then rm /etc/group cp /rom/etc/group /etc/group fi if [ -h /etc/passwd ]; then rm /etc/passwd cp /rom/etc/passwd /etc/passwd fi fi fi echo "" # add group if it doesn't exist if [ -z "$$(grep ^\\$${name}: $${IPKG_INSTROOT}/etc/group)" ]; then echo "adding group $$name to /etc/group" echo "$${name}:x:$${id}:" >> $${IPKG_INSTROOT}/etc/group fi # add user if it doesn't exist if [ -z "$$(grep ^\\$${name}: $${IPKG_INSTROOT}/etc/passwd)" ]; then echo "adding user $name to /etc/passwd" echo "$${name}:x:$${id}:$${id}:$${name}:/tmp/.$${name}:/bin/false" >> $${IPKG_INSTROOT}/etc/passwd fi endef So, let's analyze this briefly:
Another way to get scripts run after first bootplace them in:
but before modules and hotplug are loaded.
B43 driverb43 now needs CONFIG_SSB_BLOCKIO=yManaging Config filesA Common problem that usually arises in process of bumping working copy to the current HEAD is the task of keeping .config file up with the introduced changes. The correct procedure of "upgrading" config file to the newer SVN revision is to use the sequence like this: # make clean # svn update # make oldconfig make oldconfig drops out obsolete parameters and will ask you how to handle new ones (n/y/m). kernel-parameters are not part of the file - the equivalent call is make kernel_oldconfig (saved in target/linux/*/config-*). However, usually - you would accept the kernel-config(s) OpenWrt provides - in that case the kernel configs for the supported targets are adjusted and maintained by OpenWrt so you don't have to worry about. The feeds management system. is updated using the "feeds" script. This script basically does three things:
# ./scripts/feeds uninstall -a # ./scripts/feeds update -a # ./scripts/feeds install -a This will update the feeds from the corresponding repositories listed in feeds.conf / feeds.conf.default respectively.
tcpdump -i prism0 [-y PRISM_HEADER] -s0 -w dumpfile ether host 01:0c:cc:0:0:0
then running make oldconfig will now drop obsolete entries and ask you what to do with new ones (=new packages).View Wireless Traffictcpdump -i prism0 [-y PRISM_HEADER] -s0 -e -n ether host 01:0c:cc:0:0:0
UCI for UbuntuAnton <antoine@7degrees.co.za> http://7degrees.co.za/~antoine
maintains a Ubuntu repository at:
https://launchpad.net/~afrimesh/+archive/ppaDEPENDS vs PKG_BUILD_DEPENDSPKG_BUILD_DEPENDS:=libnotimp
define Package/qolyester SECTION:=net C ATEGORY:=Network DEPENDS:=+libpthread TITLE:=OLSR implementation with QoS URL:=http://qolsr.lri.fr/code/ endef The "DEPENDS" directive implies both an installation and a build time dependency
The "PKG_BUILD_DEPENDS" directive means that libnotimpl will not be selected, but it will be built before this package.
Package debuggingTo disable stripping of a package so that symbols are reserved fro debugging:add a line:
RSTRIP := true |
OpenWrt >