source: hybrid/branches/releng-10/nanobsd/tools/package-build.sh@ 13483

Last change on this file since 13483 was 13483, checked in by rick, 9 years ago

Migrating package building to poudriere [dry-coded]

https://www.wirelessleiden.nl/projects/nodefactory/wiki/Poudriere

  • Property svn:eol-style set to LF
  • Property svn:executable set to *
File size: 1.2 KB
Line 
1#!/bin/sh
2#
3# Compile listing of required packages using poudriere and friends
4#
5# Rick van der Zwet <rick@wirelessleiden.nl>
6#
7
8. `dirname $0`/common.inc.sh
9
10cfg_dir=`dirname $0`/../cfg
11poudriere_pkglist_file=${cfg_dir}/wlpkgbuild10_2-default-node-pkglist
12
13
14packages_initenv() {
15 config_dir=`dirname $0`
16
17 # Install required deamons
18 pkg install poudriere dialog4ports portshaker
19
20 # Setup poudriere build environment
21 poudriere jail -c -j wlpkgbuild10_2 -v 10.2-RELEASE -a i386
22
23 # Setup portshaker
24 cp ${config_dir}/portshaker.conf /usr/local/etc/
25 cp ${config_dir}/portshaker.d/* /usr/local/etc/portshaker.d
26
27 # Update ports
28 portshaker -U
29 portshaker -M
30
31 # Setup poudriere ports environment
32 poudriere ports -c -F -f none -p default -M /usr/local/poudriere/ports/default
33
34 # Build options
35 poudriere options -j wlpkgbuild10_2 -p default -z node -f ${poudriere_pkglist_file}
36}
37
38
39package_build() {
40 poudriere bulk -j wlpkgbuild10_2 -p default -z node -f ${poudriere_pkglist_file}
41}
42
43# Make package list
44. $cfg_dir/nanobsd.wleiden
45echo $PACKAGE_LIST | tr " " "\n" > ${poudriere_pkglist_file}
46
47
48if [ "x$1" = "xinitenv" ]; then
49 packages_initenv
50elif [ "x$1" = "xbuild" ]; then
51 package_build
52else
53 echo "Usage $0 <initenv|build>"
54 exit 128
55fi
Note: See TracBrowser for help on using the repository browser.