code stringlengths 1 1.96M | language stringclasses 1
value |
|---|---|
#!/bin/sh
set -e
qemu_version=`head ${QEMU_ROOT:-.}/VERSION`
target=i386-stubdom
mkdir -p $target
ln -sf ${QEMU_ROOT:-..}/Makefile.target $target/Makefile
#----------
cat <<END >$target/config.mak.new
QEMU_ROOT ?= ..
XEN_ROOT ?= \$(QEMU_ROOT)/../xen-unstable.hg
include ../config-host.mak
TARGET_ARCH=i386
TARGET_PA... | Shell |
#!/bin/sh
cat > .gcrypt.c << EOF
#include <gcrypt.h>
int main(void)
{
gcry_md_hash_buffer(GCRY_MD_MD5, NULL, NULL, 0);
return 0;
}
EOF
if $1 -o .gcrypt .gcrypt.c -lgcrypt 2>/dev/null ; then
echo "yes"
else
echo "no"
fi
rm -f .gcrypt*
| Shell |
#!/bin/bash
usage () { echo "USAGE: xmsnap <VM ID> <Backing File>"; }
#
# Check Usage
#
if [ -n "$1" ]
then
vmid=$1
else
usage
exit 1
fi
if [ -n "$2" ]
then
target=$2
else
usage
exit 1
fi
if [ -e "$target" ]
then
echo "Creating snapshot of file $target for VM $vmid."
else
usage
echo "File $target ... | Shell |
#!/bin/bash
#
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful, but
# WITH... | Shell |
#!/bin/bash
#
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful, but
# WITH... | Shell |
#!/bin/bash
#
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful, but
# WITH... | Shell |
#!/bin/bash
#
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful, but
# WITH... | Shell |
#!/bin/bash
#
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful, but
# WITH... | Shell |
#!/bin/bash
#
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful, but
# WITH... | Shell |
#!/bin/bash
#
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful, but
# WITH... | Shell |
#!/bin/bash
#
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful, but
# WITH... | Shell |
#!/bin/bash
#
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful, but
# WITH... | Shell |
#!/bin/bash
#
# Software injection based test cases: test cases are triggered via
# mce-inject tool.
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foun... | Shell |
#!/bin/bash
#
# Software injection based test cases: test cases are triggered via
# mce-inject tool.
# Copyright (c) 2010, Intel Corporation
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version
# 2 as published by the Free Software Foun... | Shell |
#!/bin/bash
#
# This script builds python in the dir
# installed/python-${DEST} from package downloads/Python-{PKG_VERS}.tgz
#
set -e
REG_TEST_DIR=$1
DEST=$2
PKG_VERS=$3
SUB_MAKES_MINUS_J=-j4
BUILD_DIR=${REG_TEST_DIR}/build
mkdir -p ${BUILD_DIR}
(cd ${BUILD_DIR} && tar -xf ${REG_TEST_DIR}/downloads/Python-$PKG_VE... | Shell |
#!/bin/bash
#
# Downloads python with version $1 and stores in into the downloads dir.
#
set -e
REG_TEST_DIR=$1
VERSION=$2
mkdir -p ${REG_TEST_DIR}/downloads
wget -q -O ${REG_TEST_DIR}/downloads/Python-${VERSION}.tgz http://www.python.org/ftp/python/${VERSION}/Python-${VERSION}.tgz
| Shell |
#!/bin/bash
#
# Checks the syntax of all .py files
# (compiles them into .pyc files)
#
REG_TEST_DIR=$1
# Python version, e.g. python-2.3
PYTHON=$2
PATH_TO_CHECK=$3
echo "Syntax check for $PYTHON"
PYTHON_EXECUTABLE=`echo $PYTHON | tr -d "-"`
export LD_LIBRARY_PATH=${REG_TEST_DIR}/installed/$PYTHON/lib
export PATH=${RE... | Shell |
#!/bin/bash
#
# This runs the available unit-tests with all different supported
# python versions.
#
# To run this this must be 'cd'ed to the tests directory.
#
ENABLE_UNSUPPORTED=0
function usage()
{
printf "Usage: %s: [-u]\n" $0
printf " -u: run test with unsupported python versions also\n"
}
function r... | Shell |
#!/bin/bash
#
# xenballoon-monitor - monitor certain stats from xenballoond
# (run in dom0 with "watch -d xenballoon-monitor" for xentop-like output)
# updated 090610 to include tmem stats
#
# Copyright (C) 2009 Oracle Corporation and/or its affiliates.
# All rights reserved
# Written by: Dan Magenheimer <dan.magenhe... | Shell |
#!/bin/bash
#
# xenballoond Script to start and stop Xen ballooning daemon.
#
# Copyright (C) 2009 Oracle Corporation and/or its affiliates.
# All rights reserved.
# Written by: Dan Magenheimer <dan.magenheimer@oracle.com>
#
# chkconfig: 2345 98 01
# description: Starts and stops the Xen ballooning daemon.
### BEGIN IN... | Shell |
#!/bin/bash
#
# Copyright (C) 2008 Oracle Corporation and/or its affiliates.
# All rights reserved.
# Written by: Dan Magenheimer <dan.magenheimer@oracle.com>
#
# xenballoond - In-guest engine for Xen memory ballooning
# Original version: 080630
# Updated 0906XX: add tmem preswap auto-shrinking
#
# Two self-ballooning ... | Shell |
#!/bin/sh
cat > .gcrypt.c << EOF
#include <gcrypt.h>
int main(void) { return 0; }
EOF
if $1 -o .gcrypt .gcrypt.c -lgcrypt 2>/dev/null ; then
echo "yes"
else
echo "no"
fi
rm -f .gcrypt*
| Shell |
#!/bin/sh
#
# PROVIDE: xendomains
# REQUIRE: xend
# KEYWORD: shutdown
#
# xendomains This required variable is a whitespace-separated
# list of domains, e.g., xendomains="dom1 dom2 dom3".
#
# xendomains_config This optional variable is a format string that
# represents the path to the configuration file for
# ea... | Shell |
#!/bin/sh
#
# PROVIDE: xend
# REQUIRE: xencommons
. /etc/rc.subr
DIR=$(dirname "$0")
. "${DIR}/xen-hotplugpath.sh"
LD_LIBRARY_PATH="${LIBDIR}"
export LD_LIBRARY_PATH PYTHONPATH
PATH="${PATH}:${SBINDIR}"
export PATH
name="xend"
rcvar=$name
command="${SBINDIR}/xend"
command_args="start"
command_interpreter=`head -n 1... | Shell |
#!/bin/sh
#
# PROVIDE: xen-watchdog
# REQUIRE: DAEMON
#
# description: Run domain watchdog daemon
#
. /etc/rc.subr
DIR=$(dirname "$0")
. "${DIR}/xen-hotplugpath.sh"
LD_LIBRARY_PATH="${LIBDIR}"
export LD_LIBRARY_PATH
name="xenwatchdog"
rcvar=$name
command="${SBINDIR}/xenwatchdogd"
start_cmd="echo Starting ${name}. &... | Shell |
#!/bin/sh
#
# PROVIDE: xencommons
# REQUIRE: DAEMON
. /etc/rc.subr
DIR=$(dirname "$0")
. "${DIR}/xen-hotplugpath.sh"
LD_LIBRARY_PATH="${LIBDIR}"
export LD_LIBRARY_PATH
name="xencommons"
rcvar=xend
start_precmd="xen_precmd"
start_cmd="xen_startcmd"
stop_cmd="xen_stop"
status_cmd="xen_status"
extra_commands="status"
... | Shell |
#!/bin/sh -e
# $NetBSD: vif-bridge-nbsd,v 1.1.1.1 2008/08/07 20:26:57 cegger Exp $
# Called by xenbackendd
# Usage: vif-bridge xsdir_backend_path state
DIR=$(dirname "$0")
. "${DIR}/hotplugpath.sh"
PATH=${BINDIR}:${SBINDIR}:${LIBEXEC}:${PRIVATE_BINDIR}:/bin:/usr/bin:/sbin:/usr/sbin
export PATH
xpath=$1
xstatus=$2
... | Shell |
#!/bin/sh -e
# $NetBSD: vif-ip-nbsd,v 1.1.1.1 2008/08/07 20:26:57 cegger Exp $
# Called by xenbackendd
# Usage: vif-ip xsdir_backend_path state
DIR=$(dirname "$0")
. "${DIR}/hotplugpath.sh"
PATH=${BINDIR}:${SBINDIR}:${LIBEXEC}:${PRIVATE_BINDIR}:/bin:/usr/bin:/sbin:/usr/sbin
export PATH
xpath=$1
xstatus=$2
case $xs... | Shell |
#!/bin/sh -e
# $NetBSD: block-nbsd,v 1.1.1.1 2008/08/07 20:26:57 cegger Exp $
# Called by xenbackendd
# Usage: block xsdir_backend_path state
DIR=$(dirname "$0")
. "${DIR}/hotplugpath.sh"
PATH=${BINDIR}:${SBINDIR}:${LIBEXEC}:${PRIVATE_BINDIR}:/bin:/usr/bin:/sbin:/usr/sbin
export PATH
error() {
echo "$@" >&2
xenst... | Shell |
#!/bin/sh
#
# Copyright (c) 2007, FUJITSU Limited
# Based on the block scripts code.
#
dir=$(dirname "$0")
. "$dir/xen-hotplug-common.sh"
findCommand "$@"
case "$command" in
add)
success
;;
remove)
# TODO
exit 0
;;
esac
exit 0
| Shell |
#!/bin/bash
#============================================================================
# ${XEN_SCRIPT_DIR}/vif-bridge
#
# Script for configuring a vif in bridged mode.
# The hotplugging system will call this script if it is specified either in
# the device configuration given to Xend, or the default Xend configurati... | Shell |
#
# Copyright (c) 2005 IBM Corporation
# Copyright (c) 2005 XenSource Ltd.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope tha... | Shell |
#!/bin/bash
# Usage: block-enbd [bind server ctl_port |unbind node]
#
# The node argument to unbind is the name of the device node we are to
# unbind.
#
# This assumes you're running a correctly configured server at the other end!
dir=$(dirname "$0")
. "$dir/block-common.sh"
case "$command" in
add)
for dev in ... | Shell |
#! /bin/bash
dir=$(dirname "$0")
. "$dir/xen-hotplug-common.sh"
# Claim the lock protecting ${XEN_SCRIPT_DIR}/block. This stops a race whereby
# paths in the store would disappear underneath that script as it attempted to
# read from the store checking for device sharing.
# Any other scripts that do similar things w... | Shell |
#
# Copyright (c) 2005 XenSource Ltd.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT AN... | Shell |
#
# Copyright (c) 2005 XenSource Ltd.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT AN... | Shell |
#!/bin/bash
if test "$script"
then
exec $script $*
else
exec /etc/xen/scripts/vif-bridge $*
fi
| Shell |
#!/bin/bash
# Copyright (c) 2005 IBM Corporation
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope that it will be useful,
# bu... | Shell |
#
# Copyright (c) 2005 IBM Corporation
# Copyright (c) 2005 XenSource Ltd.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope tha... | Shell |
#!/bin/bash -x
#============================================================================
# Default Xen network start/stop script when using NAT.
# Xend calls a network script when it starts.
# The script name to use is defined in ${XEN_CONFIG_DIR}/xend-config.sxp
# in the network-script field.
#
# Usage:
#
# networ... | Shell |
#!/bin/bash
#============================================================================
# Default Xen network start/stop script.
# Xend calls a network script when it starts.
# The script name to use is defined in ${XEN_CONFIG_DIR}/xend-config.sxp
# in the network-script field.
#
# This script creates a bridge (defau... | Shell |
#
# Copyright (c) 2005 XenSource Ltd.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT AN... | Shell |
#!/bin/bash
dir=$(dirname "$0")
. "$dir/vtpm-hotplug-common.sh"
vtpm_fatal_error=0
case "$command" in
add)
vtpm_create_instance
;;
remove)
vtpm_remove_instance
;;
esac
if [ $vtpm_fatal_error -eq 0 ]; then
log debug "Successful vTPM operation '$command'."
success
else
fatal "Error while executing ... | Shell |
#
# Copyright (c) 2005 XenSource Ltd.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT AN... | Shell |
#
# Copyright (c) 2005 XenSource Ltd.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT AN... | Shell |
#!/bin/bash
#============================================================================
# ${XEN_SCRIPT_DIR}/vif-nat
#
# Script for configuring a vif in routed-nat mode.
# The hotplugging system will call this script if it is specified either in
# the device configuration given to Xend, or the default Xend configurati... | Shell |
#
# Copyright (c) 2005 XenSource Ltd.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT AN... | Shell |
#!/bin/bash
# This scripts must be called the following way:
# vtpm-delete <vtpm uuid>
# or
# vtpm-delete --vmname <vm name>
dir=$(dirname "$0")
. "$dir/vtpm-common.sh"
if [ "$1" == "--vmname" ]; then
vtpm_uuid=$(vtpm_uuid_from_vmname $2)
if [ "$vtpm_uuid" != "" ];then
vtpm_delete_instance $vtpm_uuid
fi
else
v... | Shell |
#!/bin/bash
#============================================================================
# ${XEN_SCRIPT_DIR}/vif-route
#
# Script for configuring a vif in routed mode.
# The hotplugging system will call this script if it is specified either in
# the device configuration given to Xend, or the default Xend configuration... | Shell |
#!/bin/bash
# Copyright (c) 2005, XenSource Ltd.
dir=$(dirname "$0")
. "$dir/xen-hotplug-common.sh"
. "$dir/block-common.sh"
findCommand "$@"
##
# check_blktap_sharing file mode
#
# Perform the sharing check for the given blktap and mode.
#
check_blktap_sharing()
{
local file="$1"
local mode="$2"
local... | Shell |
#!/bin/bash
# ===================================================================
#
# Copyright (c) 2005, Intel Corp.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# * Redistributions o... | Shell |
#!/bin/bash
#============================================================================
# Default Xen network start/stop script.
# Xend calls a network script when it starts.
# The script name to use is defined in ${XEN_CONFIG_DIR}/xend-config.sxp
# in the network-script field.
#
# Usage:
#
# network-route (start|sto... | Shell |
#! /bin/bash
PATH=/etc/xen/scripts:$PATH
. /etc/xen/scripts/locking.sh
claim_lock xenbus_hotplug_global
case "$XENBUS_TYPE" in
tap)
/etc/xen/scripts/blktap "$ACTION"
;;
vbd)
/etc/xen/scripts/block "$ACTION"
;;
vtpm)
/etc/xen/scripts/vtpm "$ACTION"
;;
vif)
[ -n "$script" ] && $scr... | Shell |
#!/bin/bash
#
# /etc/init.d/xendomains
# Start / stop domains automatically when domain 0 boots / shuts down.
#
# chkconfig: 345 99 00
# description: Start / stop Xen domains.
#
# This script offers fairly basic functionality. It should work on Redhat
# but also on LSB-compliant SuSE releases and on Debian with the LS... | Shell |
#!/bin/bash
#
# xend Script to start and stop the Xen control daemon.
#
# Author: Keir Fraser <keir.fraser@cl.cam.ac.uk>
#
# chkconfig: 2345 98 01
# description: Starts and stops the Xen control daemon.
### BEGIN INIT INFO
# Provides: xend
# Required-Start: $syslog $remote_fs xenstored xenconsoled
#... | Shell |
#! /bin/bash
#
# xen-watchdog
#
# chkconfig: 2345 21 79
# description: Run domain watchdog daemon
### BEGIN INIT INFO
# Provides: xen-watchdog
# Required-Start: $syslog $remote_fs
# Should-Start: xend
# Required-Stop: $syslog $remote_fs
# Should-Stop: xend
# Default-Start: 2 3 4 5
# Defau... | Shell |
#!/bin/bash
#
# xencommons Script to start and stop xenstored and xenconsoled
#
# Author: Ian Jackson <ian.jackson@eu.citrix.com>
#
# chkconfig: 2345 70 10
# description: Starts and stops xenstored and xenconsoled
### BEGIN INIT INFO
# Provides: xenstored xenconsoled
# Required-Start: $syslog $remo... | Shell |
#!/bin/bash
dir=$(dirname "$0")
. "$dir/block-common.sh"
expand_dev() {
local dev
case $1 in
/*)
dev=$1
;;
*)
dev=/dev/$1
;;
esac
echo -n $dev
}
find_free_loopback_helper() {
local next_devnum=0
local busy_devnum
while read busy_devnum; do
if [ "$next_devnum" != "$busy_devnum" ]... | Shell |
#!/bin/bash
# Usage: block-nbd [bind server ctl_port |unbind node]
#
# The node argument to unbind is the name of the device node we are to
# unbind.
#
# This assumes you're running a correctly configured server at the other end!
dir=$(dirname "$0")
. "$dir/block-common.sh"
case "$command" in
add)
for dev in /... | Shell |
#
# Copyright (c) 2005 XenSource Ltd.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT AN... | Shell |
#
# Copyright (c) 2005 IBM Corporation
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the GNU Lesser General Public
# License as published by the Free Software Foundation.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT A... | Shell |
#!/bin/bash
dir=$(dirname "$0")
. "$dir/xen-hotplug-common.sh"
. "$dir/xen-network-common.sh"
bridge=$(xenstore_read_default "$XENBUS_PATH/bridge" "$bridge")
if [ -z "$bridge" ]
then
nr_bridges=$(($(brctl show | cut -f 1 | grep -v "^$" | wc -l) - 1))
if [ "$nr_bridges" != 1 ]
then
fatal "no bridge speci... | Shell |
#!/bin/sh
cat >ext2-test.c <<EOF
#include <ext2fs/ext2fs.h>
int main()
{
ext2fs_open2;
}
EOF
${CC-gcc} -o ext2-test ext2-test.c -lext2fs >/dev/null 2>&1
if [ $? = 0 ]; then
echo ext2fs-lib
else
echo ext2fs
fi
rm -f ext2-test ext2-test.c
exit 0
| Shell |
#!/bin/sh
# prepend CROSS_BIN_PATH to find the right "strip"
if [ -n "$CROSS_BIN_PATH" ]; then
PATH="$CROSS_BIN_PATH:$PATH"
fi
exec $_INSTALL "$@"
| Shell |
#!/bin/sh
mount -a
# If we're running 2.6, make sure /sys is mounted
if uname -r | grep -q '^2.6'; then
mount -t sysfs none /sys
fi
# If the block, net, and packet drivers are modules, we need to load them
if test -e /modules/xenblk.ko; then
insmod /modules/xenblk.ko > /dev/null 2>&1
fi
if test -e /modules/xennet.... | Shell |
#!/bin/sh
if [ "$1" = "" ]
then
arch=""
else
echo "Invalid architecture specified." >&2
exit 1
fi
set -eu
tempdir=$(mktemp -d)
dir=$(dirname "$0")
cd $(dirname "$dir")
./autogen
./configure
cd "$dir"
rm -Rf buildroot
make $arch initrd.img
initrd=$(readlink "initrd.img")
prefix=$(basename "$initrd" ".img"... | Shell |
#!/bin/sh
# Dan Smith <danms@us.ibm.com> - 16-Sep-2005
#
# This script takes all the .report files in the current
# directory and generates a summary table, showing the
# number of PASS, FAIL, XPASS, and XFAIL tests in each
# report
echo " Platform | PASS | FAIL | XPASS | XFAIL |"
echo "----------------... | Shell |
#!/bin/sh
##
## Test driver script
##
usage() {
echo "Usage: $0 [opts] <report>"
echo " Where report is a name that will be used for report files"
echo ""
echo " Where opts are:"
echo " -d : do not submit a report for this run"
echo " -b : do not ask any questions (batch... | Shell |
#! /bin/sh -ex
# if libtool is ever added, turn this on
# libtoolize --copy --force --automake
aclocal
automake --add-missing --copy --foreign
autoconf
chmod a+x runtest.sh
| Shell |
#!/bin/sh
passes=0
fails=0
echo "Test run starting at" `date`
while [ $# -ge 1 ] ; do
this_test=$1
shift
echo "Starting $this_test"
$this_test 2>&1
res=$?
if [ $res -eq 0 ] ; then str="" ; passes=$[passes + 1] ; else str=" -- FAILED" ; fails=$[fails + 1] ; fi
echo "Completed $this_test with $res$str".
done
e... | Shell |
#!/bin/sh
# CHECK-BUILD CHECK-INSTALL
. ./funcs.sh
if [ ! "$LIBXENAPI_BINDINGS" = "y" -a ! "$ACM_SECURITY" = "y" ]
then
echo -n "unused, "
exit 0
fi
has_or_fail xml2-config
xml2_libs=`xml2-config --libs` || fail "xml2-config --libs failed"
test_link $xml2_libs || fail "dependency libraries for xml2 are missi... | Shell |
#!/bin/sh
# CHECK-BUILD CHECK-INSTALL
. ./funcs.sh
if test -z ${PYTHON}; then
PYTHON=python
fi
${PYTHON} -c '
import sys
sys.exit(sys.version_info[0] < 2 or sys.version_info[1] < 2)
' || fail "need python version >= 2.2"
| Shell |
#!/bin/sh
# CHECK-BUILD
. ./funcs.sh
has_header uuid.h || \
has_header uuid/uuid.h || fail "missing uuid headers (package uuid-dev)"
| Shell |
#!/bin/sh
# CHECK-BUILD
. ./funcs.sh
has_or_fail xgettext
| Shell |
#!/bin/sh
# CHECK-BUILD
. ./funcs.sh
has_header openssl/md5.h || fail "missing openssl headers"
| Shell |
#!/bin/sh
# CHECK-BUILD
. ./funcs.sh
if test -z ${PYTHON}; then
PYTHON=python
fi
has_or_fail ${PYTHON}
${PYTHON} -c '
import os.path, sys
for p in sys.path:
if os.path.exists(p + "/config/Makefile"):
sys.exit(0)
sys.exit(1)
' || fail "can't find python devel files"
| Shell |
#!/bin/sh
# CHECK-BUILD CHECK-INSTALL
. ./funcs.sh
if [ "$LIBXENAPI_BINDINGS" != "y" ]; then
echo -n "unused, "
exit 0
fi
has_or_fail curl-config
curl_libs=`curl-config --libs` || fail "curl-config --libs failed"
test_link $curl_libs || fail "dependency libraries for curl are missing"
| Shell |
#!/bin/sh
func_usage ()
{
echo "Usage:"
echo " $0 [build|install|clean]"
echo
echo "Check suitability for Xen build or install."
echo "Exit with 0 if OK, 1 if not."
echo
echo "Calling with 'clean' removes generated files."
exit 1
}
PATH=$PATH:/sbin:/usr/sbin
OS=`uname -s`
export PATH O... | Shell |
#!/bin/sh
# CHECK-INSTALL
. ./funcs.sh
if test -z ${PYTHON}; then
PYTHON=python
fi
has_or_fail ${PYTHON}
${PYTHON} -c 'import xml.dom.minidom' 2>/dev/null || \
fail "can't import xml.dom.minidom"
| Shell |
#!/bin/sh
# CHECK-BUILD
. ./funcs.sh
has_header zlib.h || fail "can't find zlib headers"
| Shell |
#!/bin/sh
# CHECK-BUILD CHECK-INSTALL
. ./funcs.sh
case $OS in
FreeBSD|NetBSD|OpenBSD)
exit 0 ;;
esac
has_lib libcrypto.so || fail "missing libcrypto.so"
| Shell |
#!/bin/sh
# CHECK-BUILD
. ./funcs.sh
has_header X11/keysymdef.h || \
has_header /usr/X11R6/include/X11/keysymdef.h || \
has_header /usr/X11R7/include/X11/keysymdef.h || \
warning "can't find X11 headers"
| Shell |
#!/bin/sh
# CHECK-INSTALL
. ./funcs.sh
case $OS in
OpenBSD|NetBSD|FreeBSD)
has_or_fail brconfig ;;
Linux)
has_or_fail brctl ;;
*)
fail "unknown OS" ;;
esac
| Shell |
# has is the same as which, except it handles cross environments
has() {
if [ -z "$CROSS_COMPILE" ]; then
command which "$@"
return $?
fi
check_sys_root || return 1
# subshell to prevent pollution of caller's IFS
(
IFS=:
for p in $PATH; do
if [ -x "$CROSS_SYS_ROOT/$p/$1" ]; then
echo "$CROSS_SYS_ROOT/... | Shell |
#!/bin/sh
# CHECK-BUILD CHECK-INSTALL
. ./funcs.sh
case $OS in
FreeBSD|NetBSD|OpenBSD)
exit 0
;;
esac
has_lib libz.so || fail "can't find zlib"
| Shell |
#!/bin/sh
# CHECK-INSTALL
. ./funcs.sh
case $OS in
OpenBSD|NetBSD|FreeBSD)
has_or_fail vnconfig
;;
Linux)
has /sbin/udevadm && \
udevver=`/sbin/udevadm info -V | awk '{print $NF}'`
[ -z "$udevver" ] && has_or_fail udevinfo && \
udevver=`udevinfo -V | awk '{print $NF}'`
[ "$udevver" -ge 59 ] 2>/dev/null || \
... | Shell |
#!/bin/sh
# CHECK-INSTALL
. ./funcs.sh
PATH=/sbin:$PATH
case $OS in
OpenBSD|NetBSD|FreeBSD)
has_or_fail ifconfig ;;
Linux)
has_or_fail ip ;;
*)
fail "unknown OS" ;;
esac
| Shell |
test -n "$1" -a -n "$2" -a -n "$3"
set -ef
SED=sed
if test -x /usr/xpg4/bin/sed; then
SED=/usr/xpg4/bin/sed
fi
if test -z ${PYTHON}; then
PYTHON=`/usr/bin/env python`
fi
if test -z ${PYTHON}; then
echo "Python not found"
exit 1
fi
get_fields ()
{
local level=1 aggr=0 name= fields=
for token in $2
do
case "$t... | Shell |
#!/bin/bash
# Generate a patch for each of the ia64 files in the linux-2.6-xen-sparse tree
# Path to mercurial tree of upstream Linux
# WARNING: This will do an 'hg up -C' on the upstream Linux tree, you
# will lose data if there's anything there you care about.
: ${LINUXPATH:=/tmp/linux-2.6}
# Tag of current... | Shell |
#!/bin/sh
ME=$(basename $0)
if [ $# -lt 1 ] || [ $# -gt 2 ] ; then
echo "usage: $ME <repository-name> [search-path]" 1>&2
exit 1;
fi
REPO=$1
LINUX_SRC_PATH=$2
if [ X"${LINUX_SRC_PATH}" != X ] ; then
echo "$ME: Searching \`${LINUX_SRC_PATH}' for $REPO" 1>&2
IFS_saved="$IFS"
IFS=:
for i in $LI... | Shell |
#!/bin/sh
ME=$(basename $0)
if [ $# -lt 1 ] || [ $# -gt 2 ] ; then
echo "usage: $ME <linux-build-directory>" 1>&2
exit 1;
fi
LINUX_DIR=$1
case ${XEN_TARGET_ARCH} in
x86_32|x86_64)
if [ -d ${LINUX_DIR}/arch/x86 ] ; then
ARCH=x86
elif [ "${XEN_TARGET_ARCH}" = "x86_32" ] ; then
ARCH=i386
else
... | Shell |
#!/bin/sh
set -e
if [ $# -ne 1 ] ; then
echo "Usage $(basename $0) <config-file>" 1>&2
exit 1
fi
CONFIG=$1
setopt()
{
OPTION=$1
VALUE=$2
# First remove any existing instances of this option
sed -e "s/^# ${OPTION} is not set$//g ; s/^${OPTION}=.*$//g" -i "${CONFIG}"
# Then append the new value
case ${VALUE... | Shell |
#!/bin/sh
ME=$(basename $0)
if [ $# -lt 3 ] ; then
echo "usage: $ME <linux-build-directory> <linux-arch> <linux-targets...>" 1>&2
exit 1;
fi
LINUX_DIR=$1
LINUX_ARCH=$2
LINUX_TARGET=$3 # We don't care about second and subsequent targets
case ${XEN_TARGET_ARCH} in
ia64)
IMAGE=${LINUX_DIR}/arch/ia64/hp/si... | Shell |
#!/bin/sh
#
# Doxyfilter <source-root> <filename>
#
dir=$(dirname "$0")
PYFILTER="$dir/pythfilter.py"
if [ "${2/.py/}" != "$2" ]
then
python "$PYFILTER" -r "$1" -f "$2"
else
cat "$2"
fi
| Shell |
#! /bin/sh
if [ $1 ]; then
uname="$1"
else
uname=`uname -m`
echo "Defaulting to this machine's architecture, $uname, for linking."
echo "This may be overridden on the command line (i386,x86_64,ia64)."
fi
C=$(cd $(dirname $0) && pwd)
R=${C%/*/*}
if [ -n "$XEN" -a -d "$XEN" ]; then
XEN=$(cd $XEN && p... | Shell |
#!/bin/sh
src='./install'
if [ -d ./dist ]; then
src='./dist/install'
fi
if ! [ -d $src ]; then
echo "ERROR: Could not find a valid distribution directory."
echo " If this is a source-only release, try 'make dist'."
exit 1
fi
dst='/'
if [ $# -ne 0 ]; then
dst=$1
fi
if ! [ -d $dst ]; then
echo "ER... | Shell |
#!/bin/bash
#
# Copyright 2007-2008 Samuel Thibault <samuel.thibault@eu.citrix.net>
#
# dm script around stubdomains.
#
DIR=`dirname $0`
. "${DIR}/stubdompath.sh"
stubdom_configdir="${XEN_CONFIG_DIR}/stubdoms"
# To fit xterms nicely
height=339
# Parse arguments
domid=
domname=
vncviewer=0
vncpid=
extra=
sdl=0
openg... | Shell |
#!/bin/bash
Res=res/
Alt=donottranslate-altchars.xml
Map=donottranslate-keymap.xml
Out=assets/kbd/
mkdir -p "$Out"
for Dir in res/values res/values-*
do
[ -f $Dir/$Map ] || continue # -o -f $Dir/$Alt ] || continue
Args="$Res/values/$Alt"
[ -f $Dir/$Alt ] && Args="$Args $Dir/$Alt"
Args="$Args $Res/values/$Map... | Shell |
#!/bin/bash
getLangsForFiles () {
echo "en" # default language
for F in "$@"
do
find res/ -name "$F"
done \
| sed -n '
s/.*res.[a-z]*-\(..\)-r\(..\).*/\1_\2/p; # yy-rXX => yy_XX
s/.*res.[a-z]*-\(..\)\/.*/\1/p; # yy => yy
'
}
getLangsForDicts () {
ls ../Dicts \
| sed 's/.*-//;... | Shell |
#!/bin/sh
# START-COMMIT HOOK
#
# The start-commit hook is invoked before a Subversion txn is created
# in the process of doing a commit. Subversion runs this hook
# by invoking a program (script, executable, binary, etc.) named
# 'start-commit' (for which this file is a template)
# with the following ordered... | Shell |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.