equal
deleted
inserted
replaced
1 # |
1 # |
2 # Copyright (c) 2000, 2009, Oracle and/or its affiliates. All rights reserved. |
2 # Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved. |
3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 # |
4 # |
5 # This code is free software; you can redistribute it and/or modify it |
5 # This code is free software; you can redistribute it and/or modify it |
6 # under the terms of the GNU General Public License version 2 only, as |
6 # under the terms of the GNU General Public License version 2 only, as |
7 # published by the Free Software Foundation. |
7 # published by the Free Software Foundation. |
43 fi |
43 fi |
44 |
44 |
45 echo "EXPORTS" > vm1.def |
45 echo "EXPORTS" > vm1.def |
46 |
46 |
47 AWK="$MKS_HOME/awk.exe" |
47 AWK="$MKS_HOME/awk.exe" |
|
48 if [ ! -e $AWK ]; then |
|
49 AWK="$MKS_HOME/gawk.exe" |
|
50 fi |
48 GREP="$MKS_HOME/grep.exe" |
51 GREP="$MKS_HOME/grep.exe" |
49 SORT="$MKS_HOME/sort.exe" |
52 SORT="$MKS_HOME/sort.exe" |
50 UNIQ="$MKS_HOME/uniq.exe" |
53 UNIQ="$MKS_HOME/uniq.exe" |
51 CAT="$MKS_HOME/cat.exe" |
54 CAT="$MKS_HOME/cat.exe" |
52 RM="$MKS_HOME/rm.exe" |
55 RM="$MKS_HOME/rm.exe" |
55 # When called from IDE the first param should contain the link version, otherwise may be nill |
58 # When called from IDE the first param should contain the link version, otherwise may be nill |
56 if [ "x$1" != "x" ]; then |
59 if [ "x$1" != "x" ]; then |
57 LINK_VER="$1" |
60 LINK_VER="$1" |
58 fi |
61 fi |
59 |
62 |
60 if [ "x$LINK_VER" != "x800" -a "x$LINK_VER" != "x900" ]; then |
63 if [ "x$LINK_VER" != "x800" -a "x$LINK_VER" != "x900" -a "x$LINK_VER" != "x1000" ]; then |
61 $DUMPBIN /symbols *.obj | "$GREP" "??_7.*@@6B@" | "$GREP" -v "type_info" | "$AWK" '{print $7}' | "$SORT" | "$UNIQ" > vm2.def |
64 $DUMPBIN /symbols *.obj | "$GREP" "??_7.*@@6B@" | "$GREP" -v "type_info" | "$AWK" '{print $7}' | "$SORT" | "$UNIQ" > vm2.def |
62 else |
65 else |
63 # Can't use pipes when calling cl.exe or link.exe from IDE. Using transit file vm3.def |
66 # Can't use pipes when calling cl.exe or link.exe from IDE. Using transit file vm3.def |
64 $DUMPBIN /OUT:vm3.def /symbols *.obj |
67 $DUMPBIN /OUT:vm3.def /symbols *.obj |
65 "$CAT" vm3.def | "$GREP" "??_7.*@@6B@" | "$GREP" -v "type_info" | "$AWK" '{print $7}' | "$SORT" | "$UNIQ" > vm2.def |
68 "$CAT" vm3.def | "$GREP" "??_7.*@@6B@" | "$GREP" -v "type_info" | "$AWK" '{print $7}' | "$SORT" | "$UNIQ" > vm2.def |