builder update (sync with upstream pfsense-tools)

This commit is contained in:
Thomas NOËL 2012-05-06 01:57:22 +02:00
parent 1636513c79
commit 178cb6251d
6 changed files with 60 additions and 33 deletions

View File

@ -19,7 +19,7 @@ mkdir -p $SRCDIR
# Start building, really (pfSense scripts)
#./update_git_repos.sh
./build_pfPorts.sh
#./build_pfPorts.sh
$TOOLSDIR/builder_profiles/univnautes/builder/build_updates.sh
$TOOLSDIR/builder_profiles/univnautes/builder/build_iso.sh

View File

@ -37,9 +37,6 @@
# Suck in script helper functions
. ./builder_common.sh
#
. $TOOLSDIR/builder_profiles/univnautes/builder/univnautes_ports.sh
# If a embedded build has been performed we need to nuke
# /usr/obj.$dir/ since full uses a different
# src.conf
@ -93,7 +90,11 @@ print_flags
rebuild_and_install_bsdinstaller
# Update FreeBSD sources and install custom patches
update_freebsd_sources_and_apply_patches
if [ "$BUILDER_AUTO_UPDATE_APPLY_PATCHES" = "YES" ]; then
update_freebsd_sources_and_apply_patches
else
echo ">>> BUILDER_AUTO_UPDATE_APPLY_PATCHES is set to no. Skipping builder update and patches."
fi
# Checkout a fresh copy from pfsense cvs depot
echo ">>> Updating pfSense GIT repo..."
@ -127,9 +128,6 @@ fi
# Add extra pfSense packages
echo ">>> Phase install_custom_packages"
install_custom_packages
echo ">>> Phase univnautes_install_ports"
univnautes_install_ports
echo ">>> Phase set_image_as_cdrom"
set_image_as_cdrom
@ -144,12 +142,18 @@ rm -f $PFSPKGFILE
(pkg_info | grep bsdinstaller) > $PFSPKGFILE
(pkg_info | grep grub) >> $PFSPKGFILE
(pkg_info | grep lua) >> $PFSPKGFILE
# univnautes
(pkg_info | grep ^bash) >> $PFSPKGFILE
(pkg_info | grep ^python2) >> $PFSPKGFILE
(pkg_info | grep sqlite3) >> $PFSPKGFILE
(pkg_info | grep ^openssl) >> $PFSPKGFILE
(pkg_info | grep ^xmlsec1) >> $PFSPKGFILE
(pkg_info | grep ^wget) >> $PFSPKGFILE
(pkg_info | grep ^lasso) >> $PFSPKGFILE
(pkg_info | grep ^bsnmp-ucd) >> $PFSPKGFILE
set -e
freesbie_make pkginstall
unset PKGFILE
# Install packages needed for livecd
echo ">>> Installing packages: $PKG_INSTALL_PORTSPFS"
install_pkg_install_ports
echo ">>> Installing packages: "
@ -158,6 +162,9 @@ cat $PFSPKGFILE
# Add installer bits
cust_populate_installer_bits
freesbie_make pkginstall
unset PKGFILE
# Add extra files such as buildtime of version, bsnmpd, etc.
echo ">>> Phase populate_extra..."
cust_populate_extra
@ -186,8 +193,9 @@ fi
# Overlay final files
install_custom_overlay_final
# univnautes
echo ">>> Phase univnautes_postinst"
univnautes_postinst
chroot $PFSENSEBASEDIR /usr/local/univnautes/bin/postinst
# LiveCD specifics
setup_livecd_specifics
@ -201,6 +209,9 @@ test_php_install
# Check to see if we have a healthy installer
ensure_healthy_installer
# Overlay any loader.conf customziations
install_extra_loader_conf_options
# Create md5 summary file listing checksums
create_md5_summary_file
@ -212,13 +223,13 @@ if [ "$FBSD_VERSION" = "8" ]; then
setup_serial_hints
fi
if [ "$FBSD_VERSION" = "9" ]; then
setup_serial_hints
setup_serial_hints
fi
# Allow a custom function to be called from pfsense-build.conf
# example: disable_lan_disable_dhcpd_enable_sshd
if [ "$CUSTOM_CALL_SHELL_FUNCTION" != "" ]; then
eval $CUSTOM_CALL_SHELL_FUNCTION
eval $CUSTOM_CALL_SHELL_FUNCTION
fi
# Prepare /usr/local/pfsense-clonefs
@ -232,7 +243,9 @@ mkdir -p $CLONEDIR/home $CLONEDIR/etc
echo ">>> Finalizing iso..."
(freesbie_make iso) >/dev/null 2>&1
echo ">>> Creating memstick..."
(create_memstick_image) >/dev/null 2>&1
#(create_memstick_image) >/dev/null 2>&1
echo ">>> Creating serial memstick..."
#(create_memstick_serial_image) >/dev/null 2>&1
# Check for zero sized files. loader.conf is one of the culprits.
check_for_zero_size_files

View File

@ -37,9 +37,6 @@
# Suck in script helper functions
. ./builder_common.sh
#
. $TOOLSDIR/builder_profiles/univnautes/builder/univnautes_ports.sh
# If a embedded build has been performed we need to nuke
# /usr/obj.pfSense/ since full uses a different
# src.conf
@ -79,7 +76,7 @@ fi
freesbie_clean_each_run
# Checkout a fresh copy from pfsense cvs depot
#update_cvs_depot
update_cvs_depot
# Calculate versions
export version_kernel=`cat $CVS_CO_DIR/etc/version_kernel`
@ -94,12 +91,6 @@ make_world
echo ">>> Building all extra kernels... $FREEBSD_VERSION $FREEBSD_BRANCH ..."
build_all_kernels
# Add extra pfSense packages
echo ">>> Phase install_custom_packages"
install_custom_packages
echo ">>> Phase univnautes_install_ports"
univnautes_install_ports
# Nuke the boot directory
[ -d "${CVS_CO_DIR}/boot" ] && rm -rf ${CVS_CO_DIR}/boot
@ -108,9 +99,29 @@ rm -f $PFSPKGFILE
set +e # grep could fail
mkdir -p conf
(cd /var/db/pkg && ls | grep bsdinstaller) > $PFSPKGFILE
(cd /var/db/pkg && ls | grep rrdtool) >> $PFSPKGFILE
#(cd /var/db/pkg && ls | grep rrdtool) >> $PFSPKGFILE
# univnautes
(cd /var/db/pkg && ls | grep ^lua) >> $PFSPKGFILE
(cd /var/db/pkg && ls | grep ^bash) >> $PFSPKGFILE
(cd /var/db/pkg && ls | grep ^python2) >> $PFSPKGFILE
(cd /var/db/pkg && ls | grep sqlite3) >> $PFSPKGFILE
(cd /var/db/pkg && ls | grep ^openssl) >> $PFSPKGFILE
(cd /var/db/pkg && ls | grep ^xmlsec1) >> $PFSPKGFILE
(cd /var/db/pkg && ls | grep ^wget) >> $PFSPKGFILE
(cd /var/db/pkg && ls | grep ^lasso) >> $PFSPKGFILE
(cd /var/db/pkg && ls | grep ^bsnmp-ucd) >> $PFSPKGFILE
set -e
# Install packages needed for livecd
install_pkg_install_ports
echo ">>> Installing packages: "
cat $PFSPKGFILE
export PKGFILE=${PFSPKGFILE}
freesbie_make pkginstall
unset PKGFILE
# Add extra files such as buildtime of version, bsnmpd, etc.
echo ">>> Phase populate_extra"
cust_populate_extra
@ -131,17 +142,18 @@ find $BASE_DIR -name loader.conf -exec rm {} \;
# Install custom pfSense-XML packages from a chroot
pfsense_install_custom_packages_exec
# univnautes
echo ">>> Phase univnautes_postinst"
univnautes_postinst
chroot $PFSENSEBASEDIR /usr/local/univnautes/bin/postinst
echo ">>> remove /etc/platform in ${PFSENSEBASEDIR}"
rm -f ${PFSENSEBASEDIR}/etc/platform
# Overlay any loader.conf customziations
install_extra_loader_conf_options
create_pfSense_Full_update_tarball
#create_pfSense_Embedded_update_tarball
# Email that the operation has completed
#email_operation_completed
email_operation_completed
# Run final finish routines
finish

View File

@ -21,6 +21,6 @@ rm -rf /var/tmp/univnautes
echo ">>> Clean copy_overlay : delete univnautes virtualenv"
rm -rf $custom_overlay/usr/local/univnautes
mkdir -p $custom_overlay/usr/local
echo ">>> Copy univnautes virtualenv (/var/tmp/univnautes) in copy_overlay"
cp -a /var/tmp/univnautes $custom_overlay/usr/local
echo ">>> Copy univnautes virtualenv (/usr/local/univnautes) in copy_overlay"
cp -a /usr/local/univnautes $custom_overlay/usr/local

View File

@ -15,3 +15,6 @@ mkdir -p $SRCDIR
./clean_build.sh
echo ">>> delete virtualenv /usr/local/univnautes"
rm -rf /usr/local/univnautes

View File

@ -16,7 +16,6 @@ export PFSPORTSFILE=buildports.RELENG_2_0
# Univnautes customisations
export USE_CONFIG_XML=$BUILDER_PROFILES/univnautes/config.xml
export custom_overlay=$BUILDER_PROFILES/univnautes/copy_overlay/
export univnautes_ports="openssl python26 sqlite3 py26-sqlite3 libiconv gettext bash wget perl pkg-config pcre glib20 libltdl22 libxml2 libgpg-error libgcrypt libxslt xmlsec1 gamin gio-fam-backend lasso-2.3.99_3 bsnmp-ucd"
# outputs
export ISOPATH="/tmp/builder/univnautes-${PFSENSE_VERSION}-`date +%Y%m%d-%H%M`.iso"