When packaging LTP with rpmlinit, rpmlinit complains about several scripts which
don't have Shebang on the head of the file. Some files didn't have a Shebang at
all.
Signed-off-by: Daniel Gollub <[EMAIL PROTECTED]>
---
ltpmenu | 3 +--
testcases/commands/ade/file/file_test.sh | 2 +-
testcases/commands/cpio/cpio_tests.sh | 4 +---
testcases/commands/eject/eject-tests.sh | 2 +-
testcases/commands/fileutils/cp/cp_tests.sh | 4 +---
testcases/commands/fileutils/ln/ln_tests.sh | 4 +---
testcases/commands/fileutils/mkdir/mkdir_tests.sh | 4 +---
testcases/commands/fileutils/mv/mv_tests.sh | 4 +---
testcases/commands/gzip/gzip_tests.sh | 4 +---
testcases/commands/logrotate/logrotate_tests.sh | 5 +----
testcases/commands/mail/mail_tests.sh | 3 +--
testcases/commands/tar/tar_tests.sh | 2 +-
testcases/kernel/containers/pidns/runpidnstest.sh | 3 +--
testcases/kernel/ipc/ipc_stress/run_semaphore_test_01.sh | 3 ++-
testcases/kernel/numa/numa01.sh | 3 +--
testcases/kernel/security/filecaps/Makefile | 6 ++++--
testcases/network/dhcpd/dhcpd_tests.sh | 4 +---
testcases/network/iptables/iptables_tests.sh | 4 +---
testcases/network/traceroute/traceroute_tests.sh | 5 +----
testcases/network/xinetd/xinetd_tests.sh | 5 +----
20 files changed, 24 insertions(+), 50 deletions(-)
Index: ltp-full-20080825/ltpmenu
===================================================================
--- ltp-full-20080825.orig/ltpmenu
+++ ltp-full-20080825/ltpmenu
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -51,8 +52,6 @@
# of results file.
# - Created variable to hold results filename
# - Added time to results filename.
-#! /bin/bash
-
# Function: cleanup
#
# Description: Remove all temporary files created by this program. Cleanup
Index: ltp-full-20080825/testcases/commands/ade/file/file_test.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/ade/file/file_test.sh
+++ ltp-full-20080825/testcases/commands/ade/file/file_test.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -36,7 +37,6 @@
# Dec 18 2002 - Added. - Code to read environment variable
# LTPROOT and TMPBASE and set LTPTMP and LTPBIN
# accordingly.
-#! /bin/sh
export TST_TOTAL=10 # Number of tests in this testcase
Index: ltp-full-20080825/testcases/commands/cpio/cpio_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/cpio/cpio_tests.sh
+++ ltp-full-20080825/testcases/commands/cpio/cpio_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -28,9 +29,6 @@
#
# History: Jan 30 2003 - Created - Manoj Iyer.
#
-#! /bin/sh
-
-
# Function: init
#
# Description: - Check if command cpio is available.
Index: ltp-full-20080825/testcases/commands/eject/eject-tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/eject/eject-tests.sh
+++ ltp-full-20080825/testcases/commands/eject/eject-tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -37,7 +38,6 @@
# Jan 07 2003 - Call eject with -v for verbose information.
# Jan 08 2003 - Added test #4.
#
-#! /bin/sh
export TST_TOTAL=4
Index: ltp-full-20080825/testcases/commands/fileutils/cp/cp_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/fileutils/cp/cp_tests.sh
+++ ltp-full-20080825/testcases/commands/fileutils/cp/cp_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -28,9 +29,6 @@
# History: Jan 30 2003 - Created - Manoj Iyer.
# Feb 03 2003 - Fixed expected output.
#
-#! /bin/sh
-
-
# Function: init
#
# Description: - Check if command cp is available.
Index: ltp-full-20080825/testcases/commands/fileutils/ln/ln_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/fileutils/ln/ln_tests.sh
+++ ltp-full-20080825/testcases/commands/fileutils/ln/ln_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -27,9 +28,6 @@
#
# History: Feb 03 2003 - Created, Manoj Iyer
#
-#! /bin/sh
-
-
# Function: init
#
# Description: - Check if command ln is available.
Index: ltp-full-20080825/testcases/commands/fileutils/mkdir/mkdir_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/fileutils/mkdir/mkdir_tests.sh
+++ ltp-full-20080825/testcases/commands/fileutils/mkdir/mkdir_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -27,9 +28,6 @@
#
# History: Feb 03 2003 - Created - Manoj Iyer.
#
-#! /bin/sh
-
-
# Function: init
#
# Description: - Check if command mkdir is available.
Index: ltp-full-20080825/testcases/commands/fileutils/mv/mv_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/fileutils/mv/mv_tests.sh
+++ ltp-full-20080825/testcases/commands/fileutils/mv/mv_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -28,9 +29,6 @@
#
# History: Feb 03 2003 - Created - Manoj Iyer.
#
-#! /bin/sh
-
-
# Function: init
#
# Description: - Check if command mv is available.
Index: ltp-full-20080825/testcases/commands/gzip/gzip_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/gzip/gzip_tests.sh
+++ ltp-full-20080825/testcases/commands/gzip/gzip_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -31,9 +32,6 @@
#
# History: Fed 06 2003 - Created - Manoj Iyer.
#
-#! /bin/sh
-
-
# Function: init
#
# Description: - Check if command gunzip and gzip is available.
Index: ltp-full-20080825/testcases/commands/logrotate/logrotate_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/logrotate/logrotate_tests.sh
+++ ltp-full-20080825/testcases/commands/logrotate/logrotate_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -40,10 +41,6 @@
# cron job.
# Feb 28 2003 - Fixed - Modified testcase to use functions.
#
-#! /bin/sh
-
-
-
# Function: chk_ifexists
#
# Description: - Check if command required for this test exits.
Index: ltp-full-20080825/testcases/commands/mail/mail_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/mail/mail_tests.sh
+++ ltp-full-20080825/testcases/commands/mail/mail_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -37,8 +38,6 @@
# Jan 10 2002 - Fixed various bugs I had introduced in the test.
# - Added SETUP and CLEANUP sections
#
-#! /bin/sh
-
export TST_TOTAL=5
Index: ltp-full-20080825/testcases/commands/tar/tar_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/commands/tar/tar_tests.sh
+++ ltp-full-20080825/testcases/commands/tar/tar_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -29,7 +30,6 @@
# Dec 18 2002 - Added code to read the LTPROOT and TMPBASE
# variables to set LTPBIN and LTPTMP variables
#
-#! /bin/sh
export TST_TOTAL=1
Index: ltp-full-20080825/testcases/kernel/containers/pidns/runpidnstest.sh
===================================================================
--- ltp-full-20080825.orig/testcases/kernel/containers/pidns/runpidnstest.sh
+++ ltp-full-20080825/testcases/kernel/containers/pidns/runpidnstest.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2007
##
@@ -18,8 +19,6 @@
##
##
################################################################################
-#!/bin/sh
-
exit_code=0
pidns01
if [ $? -ne 0 ]; then
Index:
ltp-full-20080825/testcases/kernel/ipc/ipc_stress/run_semaphore_test_01.sh
===================================================================
---
ltp-full-20080825.orig/testcases/kernel/ipc/ipc_stress/run_semaphore_test_01.sh
+++ ltp-full-20080825/testcases/kernel/ipc/ipc_stress/run_semaphore_test_01.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2008
##
@@ -28,7 +29,7 @@
# History: Aug. 14 2008 - Created - Jinbing Guo.
#
################################################################################
-#! /bin/sh
+#
# Function: setup
#
# Description: - Check if required commands exits
Index: ltp-full-20080825/testcases/kernel/numa/numa01.sh
===================================================================
--- ltp-full-20080825.orig/testcases/kernel/numa/numa01.sh
+++ ltp-full-20080825/testcases/kernel/numa/numa01.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2007
##
@@ -22,8 +23,6 @@
#
# History: July 04 2007 - Created - Sivakumar Chinnaiah.
#
-#! /bin/sh
-#
# File : numa01.sh
#
# Description: Test Basic functionality of numactl command.
Index: ltp-full-20080825/testcases/network/traceroute/traceroute_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/network/traceroute/traceroute_tests.sh
+++ ltp-full-20080825/testcases/network/traceroute/traceroute_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -28,10 +29,6 @@
#
# History: Mar 03 2003 - Created - Manoj Iyer.
#
-#! /bin/sh
-
-
-
# Function: chk_ifexists
#
# Description: - Check if command required for this test exits.
Index: ltp-full-20080825/testcases/network/xinetd/xinetd_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/network/xinetd/xinetd_tests.sh
+++ ltp-full-20080825/testcases/network/xinetd/xinetd_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -27,10 +28,6 @@
#
# History: Mar 04 2003 - Created - Manoj Iyer.
#
-#! /bin/sh
-
-
-
# Function: chk_ifexists
#
# Description: - Check if command required for this test exits.
Index: ltp-full-20080825/testcases/network/dhcpd/dhcpd_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/network/dhcpd/dhcpd_tests.sh
+++ ltp-full-20080825/testcases/network/dhcpd/dhcpd_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -38,9 +39,6 @@
# if dhcpd was not running. Worked around this
# problem.
#
-#! /bin/sh
-
-
# Function: init
#
# Description: - Check if command dhcpd is available.
Index: ltp-full-20080825/testcases/network/iptables/iptables_tests.sh
===================================================================
--- ltp-full-20080825.orig/testcases/network/iptables/iptables_tests.sh
+++ ltp-full-20080825/testcases/network/iptables/iptables_tests.sh
@@ -1,3 +1,4 @@
+#!/bin/sh
################################################################################
##
##
## Copyright (c) International Business Machines Corp., 2001
##
@@ -35,9 +36,6 @@
# - Ported test01, test02 from Manoj Iyer's ipchains_tests.sh
# - Added test03, test04, test05, test06
#
-#! /bin/sh
-
-
# Function: init
#
# Description: - Check if command iptables is available.
Index: ltp-full-20080825/testcases/kernel/security/filecaps/Makefile
===================================================================
--- ltp-full-20080825.orig/testcases/kernel/security/filecaps/Makefile
+++ ltp-full-20080825/testcases/kernel/security/filecaps/Makefile
@@ -34,7 +34,8 @@ endif
all: $(TARGETS)
ifeq ($(HAVE_LIBCAP),yes)
checkforlibcap:
- echo true > $@
+ echo "#!/bin/sh" > $@
+ echo true >> $@
chmod a+rx $@
else
@echo "setcap or xattr headers not installed. Please install libcap
from"; \
@@ -42,7 +43,8 @@ else
echo "You must use libcap-2.11 or newer."; \
echo "Then make clean in ltp or ltp/testcases/kernel/security/filecaps,
and recompile ltp."
checkforlibcap:
- echo false > $@
+ echo "#!/bin/sh" > $@
+ echo false >> $@
chmod a+rx $@
endif
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list