Skip to content

Commit

Permalink
Fix Bash shebangs compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
mkow committed Feb 5, 2019
1 parent 91f1301 commit c9eb1d8
Show file tree
Hide file tree
Showing 13 changed files with 16 additions and 13 deletions.
2 changes: 1 addition & 1 deletion LibOS/shim/test/apps/apache/benchmark-ab.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

PROTOCOL=${PROTOCOL:=http}
declare -A THROUGHPUTS
Expand Down
2 changes: 1 addition & 1 deletion LibOS/shim/test/apps/bash/bash_test.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

times=$1
[ $times -gt 0 2> /dev/null ] || times=300
Expand Down
3 changes: 2 additions & 1 deletion LibOS/shim/test/apps/bash/tst.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#! /bin/sh
#!/usr/bin/env bash

###############################################################################
# The BYTE UNIX Benchmarks - Release 3
# Module: tst.sh SID: 3.4 5/15/91 19:30:24
Expand Down
3 changes: 2 additions & 1 deletion LibOS/shim/test/apps/bash/unixbench.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#! /bin/bash
#!/usr/bin/env bash

###############################################################################
# The BYTE UNIX Benchmarks - Release 3
# Module: multi.sh SID: 3.4 5/15/91 19:30:24
Expand Down
2 changes: 1 addition & 1 deletion LibOS/shim/test/apps/lighttpd/benchmark-http.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

## On Ubuntu, this script requires apache2-utils for the ab binary.
# Run like: ./benchmark-http.sh server
Expand Down
3 changes: 2 additions & 1 deletion LibOS/shim/test/apps/ltp/syscalls.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/bin/sh
#!/usr/bin/env bash

cd `dirname $0`
export LTPROOT=$PWD"/opt/ltp"
awk -v SGX=$SGX_RUN -f edit_sys_tests.awk $LTPROOT/runtest/syscalls > syscalls.graphene
Expand Down
2 changes: 1 addition & 1 deletion LibOS/shim/test/apps/python/web-test.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
#!/usr/bin/env bash

## We really need to pick a unique ephemeral port; start by just picking pid+1024
PORT=$(($$ + 1024))
Expand Down
2 changes: 1 addition & 1 deletion Pal/ipc/linux/install.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

SCRIPT=`readlink -f "${BASH_SOURCE[0]}"`
DIR=`dirname $SCRIPT`
Expand Down
2 changes: 1 addition & 1 deletion Pal/ipc/linux/load.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
#!/usr/bin/env bash

MOD=graphene-ipc
MODNAME=graphene_ipc
Expand Down
2 changes: 1 addition & 1 deletion Pal/ipc/linux/uninstall.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

DIR=`readlink -f "${BASH_SOURCE[0]}"`
MOD=graphene-ipc
Expand Down
2 changes: 1 addition & 1 deletion Runtime/pal_loader
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

if [ "$1" == "SGX" ]; then
if [ "$SGX" != "0" ]; then
Expand Down
2 changes: 1 addition & 1 deletion Scripts/list-all-graphene.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

ID=`id -u`
PGIDS=`ps -a -o pgid,command | tail -n +2 | \
Expand Down
2 changes: 1 addition & 1 deletion Tools/gsce
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ def gen_app_executor(app_name, bin_cmd, proj_dir) :
print "e_path: " + e_path
ef = open(e_path, "w")
make_exec(e_path)
ef.write('#!/bin/bash \n \n')
ef.write('#!/usr/bin/env bash\n\n')
ef.write('cd ' + proj_dir + '/LibOS/shim/test/apps/' + app_name +'\n')
ef.write('# Generate EINITOKEN \n')
ef.write(proj_dir + '/Pal/src/host/Linux-SGX/signer/pal-sgx-get-token -output '
Expand Down

0 comments on commit c9eb1d8

Please sign in to comment.