comparison test/runtime/7107135/Test7107135.sh @ 15280:417e2ae45b89

Merge
author Michael Van De Vanter <michael.van.de.vanter@oracle.com>
date Tue, 22 Apr 2014 18:22:40 -0700
parents 4ca6dc0799b6
children
comparison
equal deleted inserted replaced
15279:0c6d8a08e31b 15280:417e2ae45b89
1 #!/bin/sh 1 #!/bin/sh
2 2
3 # 3 #
4 # Copyright (c) 1998, 2014, Oracle and/or its affiliates. All rights reserved. 4 # Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
5 # Copyright (c) 2011 SAP AG. All Rights Reserved. 5 # Copyright (c) 2011 SAP AG. All Rights Reserved.
6 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 6 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
7 # 7 #
8 # This code is free software; you can redistribute it and/or modify it 8 # This code is free software; you can redistribute it and/or modify it
9 # under the terms of the GNU General Public License version 2 only, as 9 # under the terms of the GNU General Public License version 2 only, as
23 # or visit www.oracle.com if you need additional information or have any 23 # or visit www.oracle.com if you need additional information or have any
24 # questions. 24 # questions.
25 # 25 #
26 26
27 ## 27 ##
28 ## @ignore 8025519
29 ## @test Test7107135.sh 28 ## @test Test7107135.sh
30 ## @bug 7107135 29 ## @bug 7107135
31 ## @bug 8021296 30 ## @bug 8021296
32 ## @bug 8025519
33 ## @summary Stack guard pages lost after loading library with executable stack. 31 ## @summary Stack guard pages lost after loading library with executable stack.
34 ## @run shell Test7107135.sh 32 ## @run shell Test7107135.sh
35 ## 33 ##
36 34
37 if [ "${TESTSRC}" = "" ] 35 if [ "${TESTSRC}" = "" ]
63 ARCH=`uname -m` 61 ARCH=`uname -m`
64 62
65 THIS_DIR=. 63 THIS_DIR=.
66 64
67 cp ${TESTSRC}${FS}*.java ${THIS_DIR} 65 cp ${TESTSRC}${FS}*.java ${THIS_DIR}
68 ${COMPILEJAVA}${FS}bin${FS}javac *.java 66 ${TESTJAVA}${FS}bin${FS}javac *.java
69 67
70 $gcc_cmd -fPIC -shared -c -o test.o \ 68 $gcc_cmd -fPIC -shared -c -o test.o \
71 -I${COMPILEJAVA}${FS}include -I${COMPILEJAVA}${FS}include${FS}linux \ 69 -I${TESTJAVA}${FS}include -I${TESTJAVA}${FS}include${FS}linux \
72 ${TESTSRC}${FS}test.c 70 ${TESTSRC}${FS}test.c
73 71
74 ld -shared -z execstack -o libtest-rwx.so test.o 72 ld -shared -z execstack -o libtest-rwx.so test.o
75 ld -shared -z noexecstack -o libtest-rw.so test.o 73 ld -shared -z noexecstack -o libtest-rw.so test.o
76 74