]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
objc: reorganize basic tests
authorStefano Lattarini <stefano.lattarini@gmail.com>
Mon, 30 Apr 2012 12:30:42 +0000 (14:30 +0200)
committerStefano Lattarini <stefano.lattarini@gmail.com>
Wed, 2 May 2012 15:39:21 +0000 (17:39 +0200)
* t/objc.sh, t/objc2.sh: Removed, merged into ...
* t/objc-basic.sh: ... this new test.
* t/objcxx-basic.sh: Add reference to new sister test.
* t/list-of-tests.mk: Update.

Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
t/list-of-tests.mk
t/objc-basic.sh [moved from t/objc2.sh with 58% similarity]
t/objc.sh [deleted file]
t/objcxx-basic.sh

index d19c74a7561173542d006a0cce2f29d77a8526d6..41f8927c423364f028b2ed01e343a8f11bffa703 100644 (file)
@@ -702,8 +702,7 @@ t/nolink.sh \
 t/nostdinc.sh \
 t/notrans.sh \
 t/number.sh \
-t/objc.sh \
-t/objc2.sh \
+t/objc-basic.sh \
 t/objc-minidemo.sh \
 t/objcxx-basic.sh \
 t/objcxx-minidemo.sh \
similarity index 58%
rename from t/objc2.sh
rename to t/objc-basic.sh
index 290bf26426a4a24e34404038aec213904df9b431..f608fbc83ca78661d6b82301dd625ec2fd3318f9 100755 (executable)
@@ -1,5 +1,5 @@
 #! /bin/sh
-# Copyright (C) 2002-2012 Free Software Foundation, Inc.
+# Copyright (C) 2012 Free Software Foundation, Inc.
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
 # but WITHOUT ANY WARRANTY; without even the implied warranty of
 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 # GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# Test that Automake suggests using AC_PROG_OBJC if Objective C sources
-# are used.
+# Basic tests on the Objective C support that don't actually
+# require an Objective-C compiler.
+# See also sister test 'objcxx-basic.sh'.
 
 . ./defs || Exit 1
 
-echo AC_PROG_CC >>configure.ac
-
-cat >Makefile.am <<'END'
+cat > Makefile.am <<'END'
 bin_PROGRAMS = hello
 hello_SOURCES = hello.m
 END
 
 $ACLOCAL
 AUTOMAKE_fails
-grep AC_PROG_OBJC stderr
+grep "'OBJC'.* undefined" stderr
+grep "add .*'AC_PROG_OBJC'" stderr
+
+rm -rf autom4te*.cache
+
+echo AC_PROG_OBJC >> configure.ac
+
+$ACLOCAL
+$AUTOMAKE
+$EGREP '^\.SUFFIXES:.* \.m( |$)' Makefile.in
+
+:
diff --git a/t/objc.sh b/t/objc.sh
deleted file mode 100755 (executable)
index f56c76d..0000000
--- a/t/objc.sh
+++ /dev/null
@@ -1,36 +0,0 @@
-#! /bin/sh
-# Copyright (C) 2001-2012 Free Software Foundation, Inc.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.
-
-# Test that '.m' extension works.
-# From Ralf Corsepius (for C++).
-
-. ./defs || Exit 1
-
-cat >> configure.ac << 'END'
-AC_PROG_OBJC
-END
-
-cat > Makefile.am << 'END'
-bin_PROGRAMS = hello
-hello_SOURCES = hello.m
-END
-
-$ACLOCAL
-$AUTOMAKE
-
-grep '^\.SUFFIXES:.*\.m' Makefile.in
-
-:
index 33b80179757d506322ccfb4e3d7f515d2ad65296..be2cdf7520190409acd254b956801919426faafe 100755 (executable)
@@ -13,6 +13,7 @@
 
 # Basic tests on the Objective C++ support that don't actually
 # require an Objective-C++ compiler.
+# See also sister test 'objc-basic.sh'.
 
 . ./defs || Exit 1