Module Name: src Committed By: skrll Date: Sun Jun 12 15:08:39 UTC 2022
Modified Files: src/tests/usr.bin/c++: t_call_once.sh t_call_once2.sh t_cxxruntime.sh t_hello.sh t_pthread_once.sh t_static_destructor.sh src/tests/usr.bin/cc: t_hello.sh Log Message: Put the sprinkled -static in the right place, i.e. fix up previous. Thanks to rillig for spotting my mistake. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/tests/usr.bin/c++/t_call_once.sh \ src/tests/usr.bin/c++/t_call_once2.sh \ src/tests/usr.bin/c++/t_pthread_once.sh \ src/tests/usr.bin/c++/t_static_destructor.sh cvs rdiff -u -r1.6 -r1.7 src/tests/usr.bin/c++/t_cxxruntime.sh \ src/tests/usr.bin/c++/t_hello.sh cvs rdiff -u -r1.11 -r1.12 src/tests/usr.bin/cc/t_hello.sh Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/tests/usr.bin/c++/t_call_once.sh diff -u src/tests/usr.bin/c++/t_call_once.sh:1.5 src/tests/usr.bin/c++/t_call_once.sh:1.6 --- src/tests/usr.bin/c++/t_call_once.sh:1.5 Sun Jun 12 08:55:36 2022 +++ src/tests/usr.bin/c++/t_call_once.sh Sun Jun 12 15:08:38 2022 @@ -1,4 +1,4 @@ -# $NetBSD: t_call_once.sh,v 1.5 2022/06/12 08:55:36 skrll Exp $ +# $NetBSD: t_call_once.sh,v 1.6 2022/06/12 15:08:38 skrll Exp $ # # Copyright (c) 2018 The NetBSD Foundation, Inc. # All rights reserved. @@ -111,7 +111,7 @@ int main(void) { return 0; } EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -pg -o call_once test.cpp -pthread + atf_check -s exit:0 -o ignore -e ignore c++ -static -pg -o call_once test.cpp -pthread atf_check -s exit:0 -o inline:"hello, world!\n" ./call_once } @@ -138,7 +138,7 @@ int main(void) { return 0; } EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -m32 -pg -o call_once test.cpp -pthread + atf_check -s exit:0 -o ignore -e ignore c++ -static -m32 -pg -o call_once test.cpp -pthread atf_check -s exit:0 -o inline:"hello, world!\n" ./call_once } Index: src/tests/usr.bin/c++/t_call_once2.sh diff -u src/tests/usr.bin/c++/t_call_once2.sh:1.5 src/tests/usr.bin/c++/t_call_once2.sh:1.6 --- src/tests/usr.bin/c++/t_call_once2.sh:1.5 Sun Jun 12 08:55:36 2022 +++ src/tests/usr.bin/c++/t_call_once2.sh Sun Jun 12 15:08:38 2022 @@ -1,4 +1,4 @@ -# $NetBSD: t_call_once2.sh,v 1.5 2022/06/12 08:55:36 skrll Exp $ +# $NetBSD: t_call_once2.sh,v 1.6 2022/06/12 15:08:38 skrll Exp $ # # Copyright (c) 2018 The NetBSD Foundation, Inc. # All rights reserved. @@ -154,7 +154,7 @@ int main(void) { return 0; } EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -pg -o call_once2 test.cpp -pthread + atf_check -s exit:0 -o ignore -e ignore c++ -static -pg -o call_once2 test.cpp -pthread atf_check -s exit:0 -o inline:"hello, world!\n" ./call_once2 } @@ -198,7 +198,7 @@ int main(void) { return 0; } EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -m32 -pg -o call_once2 test.cpp -pthread + atf_check -s exit:0 -o ignore -e ignore c++ -static-m32 -pg -o call_once2 test.cpp -pthread atf_check -s exit:0 -o inline:"hello, world!\n" ./call_once2 atf_expect_fail "The combination of 32-bit and profiling should be fail" } Index: src/tests/usr.bin/c++/t_pthread_once.sh diff -u src/tests/usr.bin/c++/t_pthread_once.sh:1.5 src/tests/usr.bin/c++/t_pthread_once.sh:1.6 --- src/tests/usr.bin/c++/t_pthread_once.sh:1.5 Sun Jun 12 08:55:36 2022 +++ src/tests/usr.bin/c++/t_pthread_once.sh Sun Jun 12 15:08:38 2022 @@ -1,4 +1,4 @@ -# $NetBSD: t_pthread_once.sh,v 1.5 2022/06/12 08:55:36 skrll Exp $ +# $NetBSD: t_pthread_once.sh,v 1.6 2022/06/12 15:08:38 skrll Exp $ # # Copyright (c) 2018 The NetBSD Foundation, Inc. # All rights reserved. @@ -109,7 +109,7 @@ int main(void) { return 0; } EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -pg -o pthread_once test.cpp -pthread + atf_check -s exit:0 -o ignore -e ignore c++ -static -pg -o pthread_once test.cpp -pthread atf_check -s exit:0 -o inline:"hello, world!\n" ./pthread_once } @@ -135,7 +135,7 @@ int main(void) { return 0; } EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -m32 -pg -o pthread_once test.cpp -pthread + atf_check -s exit:0 -o ignore -e ignore c++ -static -m32 -pg -o pthread_once test.cpp -pthread atf_check -s exit:0 -o inline:"hello, world!\n" ./pthread_once } Index: src/tests/usr.bin/c++/t_static_destructor.sh diff -u src/tests/usr.bin/c++/t_static_destructor.sh:1.5 src/tests/usr.bin/c++/t_static_destructor.sh:1.6 --- src/tests/usr.bin/c++/t_static_destructor.sh:1.5 Sun Jun 12 08:55:36 2022 +++ src/tests/usr.bin/c++/t_static_destructor.sh Sun Jun 12 15:08:38 2022 @@ -1,4 +1,4 @@ -# $NetBSD: t_static_destructor.sh,v 1.5 2022/06/12 08:55:36 skrll Exp $ +# $NetBSD: t_static_destructor.sh,v 1.6 2022/06/12 15:08:38 skrll Exp $ # # Copyright (c) 2017 The NetBSD Foundation, Inc. # All rights reserved. @@ -122,7 +122,7 @@ struct B { }; int main(void) {struct B b;return 0;} EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -pg -o hello test.cpp + atf_check -s exit:0 -o ignore -e ignore c++ -static -pg -o hello test.cpp atf_check -s exit:0 -o inline:"CTOR A\nCTOR B\nDTOR B:10\nDTOR A:20\n" ./hello } @@ -153,7 +153,7 @@ struct B { }; int main(void) {struct B b;return 0;} EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -m32 -pg -o hello test.cpp + atf_check -s exit:0 -o ignore -e ignore c++ -static -m32 -pg -o hello test.cpp atf_check -s exit:0 -o inline:"CTOR A\nCTOR B\nDTOR B:10\nDTOR A:20\n" ./hello } Index: src/tests/usr.bin/c++/t_cxxruntime.sh diff -u src/tests/usr.bin/c++/t_cxxruntime.sh:1.6 src/tests/usr.bin/c++/t_cxxruntime.sh:1.7 --- src/tests/usr.bin/c++/t_cxxruntime.sh:1.6 Sun Jun 12 08:55:36 2022 +++ src/tests/usr.bin/c++/t_cxxruntime.sh Sun Jun 12 15:08:38 2022 @@ -1,4 +1,4 @@ -# $NetBSD: t_cxxruntime.sh,v 1.6 2022/06/12 08:55:36 skrll Exp $ +# $NetBSD: t_cxxruntime.sh,v 1.7 2022/06/12 15:08:38 skrll Exp $ # # Copyright (c) 2017 The NetBSD Foundation, Inc. # All rights reserved. @@ -104,7 +104,7 @@ cxxruntime_profile_body() { #include <iostream> int main(void) {std::cout << "hello world" << std::endl;exit(0);} EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -pg -o hello test.cpp + atf_check -s exit:0 -o ignore -e ignore c++ -static -pg -o hello test.cpp atf_check -s exit:0 -o inline:"hello world\n" ./hello } @@ -126,7 +126,7 @@ cxxruntime_profile_32_body() { #include <iostream> int main(void) {std::cout << "hello world" << std::endl;exit(0);} EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -m32 -pg -o hello test.cpp + atf_check -s exit:0 -o ignore -e ignore c++ -static -m32 -pg -o hello test.cpp atf_check -s exit:0 -o inline:"hello world\n" ./hello } Index: src/tests/usr.bin/c++/t_hello.sh diff -u src/tests/usr.bin/c++/t_hello.sh:1.6 src/tests/usr.bin/c++/t_hello.sh:1.7 --- src/tests/usr.bin/c++/t_hello.sh:1.6 Sun Jun 12 08:55:36 2022 +++ src/tests/usr.bin/c++/t_hello.sh Sun Jun 12 15:08:38 2022 @@ -1,4 +1,4 @@ -# $NetBSD: t_hello.sh,v 1.6 2022/06/12 08:55:36 skrll Exp $ +# $NetBSD: t_hello.sh,v 1.7 2022/06/12 15:08:38 skrll Exp $ # # Copyright (c) 2011 The NetBSD Foundation, Inc. # All rights reserved. @@ -101,7 +101,7 @@ hello_profile_body() { #include <stdlib.h> int main(void) {printf("hello world\n");exit(0);} EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -pg -o hello test.cpp + atf_check -s exit:0 -o ignore -e ignore c++ -static -pg -o hello test.cpp atf_check -s exit:0 -o inline:"hello world\n" ./hello } @@ -122,7 +122,7 @@ hello_profile_32_body() { #include <stdlib.h> int main(void) {printf("hello world\n");exit(0);} EOF - atf_check -s exit:0 -static -o ignore -e ignore c++ -m32 -pg -o hello test.cpp + atf_check -s exit:0 -o ignore -e ignore c++ -static -m32 -pg -o hello test.cpp atf_check -s exit:0 -o inline:"hello world\n" ./hello } Index: src/tests/usr.bin/cc/t_hello.sh diff -u src/tests/usr.bin/cc/t_hello.sh:1.11 src/tests/usr.bin/cc/t_hello.sh:1.12 --- src/tests/usr.bin/cc/t_hello.sh:1.11 Sun Jun 12 08:55:36 2022 +++ src/tests/usr.bin/cc/t_hello.sh Sun Jun 12 15:08:38 2022 @@ -1,4 +1,4 @@ -# $NetBSD: t_hello.sh,v 1.11 2022/06/12 08:55:36 skrll Exp $ +# $NetBSD: t_hello.sh,v 1.12 2022/06/12 15:08:38 skrll Exp $ # # Copyright (c) 2011 The NetBSD Foundation, Inc. # All rights reserved. @@ -71,7 +71,7 @@ hello_profile_body() { #include <stdlib.h> int main(void) {printf("hello world\n");exit(0);} EOF - atf_check -s exit:0 -static -o ignore -e ignore cc -o hello -pg test.c + atf_check -s exit:0 -o ignore -e ignore cc -static -o hello -pg test.c atf_check -s exit:0 -o inline:"hello world\n" ./hello atf_check -s exit:0 -o ignore -e ignore cc -o hello2 -fprofile-generate test.c atf_check -s exit:0 -o inline:"hello world\n" ./hello2