10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# This file and its contents are supplied under the terms of the
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# Common Development and Distribution License ("CDDL"), version 1.0.
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# You may only use this file in accordance with the terms of version
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# 1.0 of the CDDL.
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# A full copy of the text of the CDDL should have accompanied this
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# source. A copy of the CDDL is also available via the Internet at
b819cea2f73f98c5662230cc9affc8cc84f77fcfGordon Ross# Copyright 2014 Nexenta Systems, Inc. All rights reserved.
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# Use distributed make (dmake) by default.
b3700b074e637f8c6991b70754c88a2cfffb246bGordon Ross# Do this if you want to use dbx or gdb
b3700b074e637f8c6991b70754c88a2cfffb246bGordon Ross# export SOURCEDEBUG=yes
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross################################################################
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross test -f $SRC/tools/proto/root_i386-nd/opt/onbld/bin/genoffsets ||
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross################################################################
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross test -f $ROOT/usr/include/rpcsvc/daemon_utils.h ||
12b65585e720714b31036daaa2b30eb76014048eGordon Ross (cd $SRC/uts/common/gssapi && $make -k install_h)
12b65585e720714b31036daaa2b30eb76014048eGordon Ross (cd $SRC/uts/common/smbsrv && $make -k install_h)
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# Need some library headers too...
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross################################################################
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross################################################################
b819cea2f73f98c5662230cc9affc8cc84f77fcfGordon Ross# Note lib1 builds prerequisite libraries not delivered by the
b819cea2f73f98c5662230cc9affc8cc84f77fcfGordon Ross# tar file we create below. To accelerate clean/install, we
b819cea2f73f98c5662230cc9affc8cc84f77fcfGordon Ross# skip these on clean (but still nuke them for clobber)
b819cea2f73f98c5662230cc9affc8cc84f77fcfGordon Ross# lib2 builds stuff we include in the tar file,
b819cea2f73f98c5662230cc9affc8cc84f77fcfGordon Ross# or that we don't mind rebuilding after clean.
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross################################################################
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# Build the MDB modules, WITH the linktest
b819cea2f73f98c5662230cc9affc8cc84f77fcfGordon Ross# We build these libraries (to the proto area), so we need to
b819cea2f73f98c5662230cc9affc8cc84f77fcfGordon Ross# build the mdb modules too so mdb will load them.
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# Deal with mode 0400 file annoyance...
10b444a87400224fdb8ed3a329960a27385a96daGordon Rossif [ $1 = install ]; then
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross################################################################
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# This builds $SRC/TAGS (and cscope.files) in a helpful order.
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross find uts/common/netinet -name '*.[ch]' -print |sort
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross find uts/common/smbsrv -name '*.ndl' -print |sort
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross find uts/common/smbsrv -name '*.[ch]' -print |sort
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross find uts/common/fs/smbsrv -name '*.[ch]' -print |sort
12b65585e720714b31036daaa2b30eb76014048eGordon Ross find uts/common/gssapi -name '*.[ch]' -print |sort
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross exctags -e --langmap=c:+.ndl -h ndl -L - < cscope.files
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross################################################################
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross# This creates a tarfile one can use to update a test machine.
ed81dd52230eff1a7c7625caad21af232c36f6cbAlek Pinchuk (cd $ROOT && tar cfj ../../smbsrv-${git_rev}.tar.bz2 $files)
10b444a87400224fdb8ed3a329960a27385a96daGordon Ross################################################################
b819cea2f73f98c5662230cc9affc8cc84f77fcfGordon Ross # intentionally skip: lib1, hdrs, tools
b819cea2f73f98c5662230cc9affc8cc84f77fcfGordon Ross echo "Usage: $0 {install|lint|clean|clobber|tags|tar}";