提交 b26dab44 编写于 作者: L lana

Merge

......@@ -7,3 +7,8 @@ e21f4266466cd1306b176aaa08b2cd8337a9be3d jdk7-b29
b6d6877c1155621a175dccd12dc14c54f938fb8b jdk7-b30
b7474b739d13bacd9972f88ac91f6350b7b0be12 jdk7-b31
c51121419e30eac5f0fbbce45ff1711c4ce0de28 jdk7-b32
fa4c0a6cdd25d97d4e6f5d7aa180bcbb0e0d56af jdk7-b33
434055a0716ee44bca712ebca02fc04b20e6e288 jdk7-b34
cf4894b78ceb966326e93bf221db0c2d14d59218 jdk7-b35
134fd1a656ea85acd1f97f6700f75029b9b472a0 jdk7-b36
14f50aee4989b75934d385c56a83da0c23d2f68b jdk7-b37
OPENJDK ASSEMBLY EXCEPTION
The OpenJDK source code made available by Sun at openjdk.java.net and
openjdk.dev.java.net ("OpenJDK Code") is distributed under the terms of the
GNU General Public License <http://www.gnu.org/copyleft/gpl.html> version 2
only ("GPL2"), with the following clarification and special exception.
Linking this OpenJDK Code statically or dynamically with other code
is making a combined work based on this library. Thus, the terms
and conditions of GPL2 cover the whole combination.
As a special exception, Sun gives you permission to link this
OpenJDK Code with certain code licensed by Sun as indicated at
http://openjdk.java.net/legal/exception-modules-2007-05-08.html
("Designated Exception Modules") to produce an executable,
regardless of the license terms of the Designated Exception Modules,
and to copy and distribute the resulting executable under GPL2,
provided that the Designated Exception Modules continue to be
governed by the licenses under which they were offered by Sun.
As such, it allows licensees and sublicensees of Sun's GPL2 OpenJDK Code to
build an executable that includes those portions of necessary code that Sun
could not provide under GPL2 (or that Sun has provided under GPL2 with the
Classpath exception). If you modify or add to the OpenJDK code, that new
GPL2 code may still be combined with Designated Exception Modules if the
new code is made subject to this exception by its copyright holder.
The GNU General Public License (GPL)
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Everyone is permitted to copy and distribute verbatim copies of this license
document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your freedom to share
and change it. By contrast, the GNU General Public License is intended to
guarantee your freedom to share and change free software--to make sure the
software is free for all its users. This General Public License applies to
most of the Free Software Foundation's software and to any other program whose
authors commit to using it. (Some other Free Software Foundation software is
covered by the GNU Library General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not price. Our
General Public Licenses are designed to make sure that you have the freedom to
distribute copies of free software (and charge for this service if you wish),
that you receive source code or can get it if you want it, that you can change
the software or use pieces of it in new free programs; and that you know you
can do these things.
To protect your rights, we need to make restrictions that forbid anyone to deny
you these rights or to ask you to surrender the rights. These restrictions
translate to certain responsibilities for you if you distribute copies of the
software, or if you modify it.
For example, if you distribute copies of such a program, whether gratis or for
a fee, you must give the recipients all the rights that you have. You must
make sure that they, too, receive or can get the source code. And you must
show them these terms so they know their rights.
We protect your rights with two steps: (1) copyright the software, and (2)
offer you this license which gives you legal permission to copy, distribute
and/or modify the software.
Also, for each author's protection and ours, we want to make certain that
everyone understands that there is no warranty for this free software. If the
software is modified by someone else and passed on, we want its recipients to
know that what they have is not the original, so that any problems introduced
by others will not reflect on the original authors' reputations.
Finally, any free program is threatened constantly by software patents. We
wish to avoid the danger that redistributors of a free program will
individually obtain patent licenses, in effect making the program proprietary.
To prevent this, we have made it clear that any patent must be licensed for
everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and modification
follow.
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains a notice
placed by the copyright holder saying it may be distributed under the terms of
this General Public License. The "Program", below, refers to any such program
or work, and a "work based on the Program" means either the Program or any
derivative work under copyright law: that is to say, a work containing the
Program or a portion of it, either verbatim or with modifications and/or
translated into another language. (Hereinafter, translation is included
without limitation in the term "modification".) Each licensee is addressed as
"you".
Activities other than copying, distribution and modification are not covered by
this License; they are outside its scope. The act of running the Program is
not restricted, and the output from the Program is covered only if its contents
constitute a work based on the Program (independent of having been made by
running the Program). Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's source code as
you receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice and
disclaimer of warranty; keep intact all the notices that refer to this License
and to the absence of any warranty; and give any other recipients of the
Program a copy of this License along with the Program.
You may charge a fee for the physical act of transferring a copy, and you may
at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion of it, thus
forming a work based on the Program, and copy and distribute such modifications
or work under the terms of Section 1 above, provided that you also meet all of
these conditions:
a) You must cause the modified files to carry prominent notices stating
that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in whole or
in part contains or is derived from the Program or any part thereof, to be
licensed as a whole at no charge to all third parties under the terms of
this License.
c) If the modified program normally reads commands interactively when run,
you must cause it, when started running for such interactive use in the
most ordinary way, to print or display an announcement including an
appropriate copyright notice and a notice that there is no warranty (or
else, saying that you provide a warranty) and that users may redistribute
the program under these conditions, and telling the user how to view a copy
of this License. (Exception: if the Program itself is interactive but does
not normally print such an announcement, your work based on the Program is
not required to print an announcement.)
These requirements apply to the modified work as a whole. If identifiable
sections of that work are not derived from the Program, and can be reasonably
considered independent and separate works in themselves, then this License, and
its terms, do not apply to those sections when you distribute them as separate
works. But when you distribute the same sections as part of a whole which is a
work based on the Program, the distribution of the whole must be on the terms
of this License, whose permissions for other licensees extend to the entire
whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest your
rights to work written entirely by you; rather, the intent is to exercise the
right to control the distribution of derivative or collective works based on
the Program.
In addition, mere aggregation of another work not based on the Program with the
Program (or with a work based on the Program) on a volume of a storage or
distribution medium does not bring the other work under the scope of this
License.
3. You may copy and distribute the Program (or a work based on it, under
Section 2) in object code or executable form under the terms of Sections 1 and
2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable source
code, which must be distributed under the terms of Sections 1 and 2 above
on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three years, to
give any third party, for a charge no more than your cost of physically
performing source distribution, a complete machine-readable copy of the
corresponding source code, to be distributed under the terms of Sections 1
and 2 above on a medium customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer to
distribute corresponding source code. (This alternative is allowed only
for noncommercial distribution and only if you received the program in
object code or executable form with such an offer, in accord with
Subsection b above.)
The source code for a work means the preferred form of the work for making
modifications to it. For an executable work, complete source code means all
the source code for all modules it contains, plus any associated interface
definition files, plus the scripts used to control compilation and installation
of the executable. However, as a special exception, the source code
distributed need not include anything that is normally distributed (in either
source or binary form) with the major components (compiler, kernel, and so on)
of the operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering access to copy
from a designated place, then offering equivalent access to copy the source
code from the same place counts as distribution of the source code, even though
third parties are not compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program except as
expressly provided under this License. Any attempt otherwise to copy, modify,
sublicense or distribute the Program is void, and will automatically terminate
your rights under this License. However, parties who have received copies, or
rights, from you under this License will not have their licenses terminated so
long as such parties remain in full compliance.
5. You are not required to accept this License, since you have not signed it.
However, nothing else grants you permission to modify or distribute the Program
or its derivative works. These actions are prohibited by law if you do not
accept this License. Therefore, by modifying or distributing the Program (or
any work based on the Program), you indicate your acceptance of this License to
do so, and all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the Program),
the recipient automatically receives a license from the original licensor to
copy, distribute or modify the Program subject to these terms and conditions.
You may not impose any further restrictions on the recipients' exercise of the
rights granted herein. You are not responsible for enforcing compliance by
third parties to this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues), conditions
are imposed on you (whether by court order, agreement or otherwise) that
contradict the conditions of this License, they do not excuse you from the
conditions of this License. If you cannot distribute so as to satisfy
simultaneously your obligations under this License and any other pertinent
obligations, then as a consequence you may not distribute the Program at all.
For example, if a patent license would not permit royalty-free redistribution
of the Program by all those who receive copies directly or indirectly through
you, then the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under any
particular circumstance, the balance of the section is intended to apply and
the section as a whole is intended to apply in other circumstances.
It is not the purpose of this section to induce you to infringe any patents or
other property right claims or to contest validity of any such claims; this
section has the sole purpose of protecting the integrity of the free software
distribution system, which is implemented by public license practices. Many
people have made generous contributions to the wide range of software
distributed through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing to
distribute software through any other system and a licensee cannot impose that
choice.
This section is intended to make thoroughly clear what is believed to be a
consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in certain
countries either by patents or by copyrighted interfaces, the original
copyright holder who places the Program under this License may add an explicit
geographical distribution limitation excluding those countries, so that
distribution is permitted only in or among countries not thus excluded. In
such case, this License incorporates the limitation as if written in the body
of this License.
9. The Free Software Foundation may publish revised and/or new versions of the
General Public License from time to time. Such new versions will be similar in
spirit to the present version, but may differ in detail to address new problems
or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any later
version", you have the option of following the terms and conditions either of
that version or of any later version published by the Free Software Foundation.
If the Program does not specify a version number of this License, you may
choose any version ever published by the Free Software Foundation.
10. If you wish to incorporate parts of the Program into other free programs
whose distribution conditions are different, write to the author to ask for
permission. For software which is copyrighted by the Free Software Foundation,
write to the Free Software Foundation; we sometimes make exceptions for this.
Our decision will be guided by the two goals of preserving the free status of
all derivatives of our free software and of promoting the sharing and reuse of
software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR
THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE
STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE
PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND
PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE,
YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL
ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE
PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR
INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA
BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER
OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest possible
use to the public, the best way to achieve this is to make it free software
which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest to attach
them to the start of each source file to most effectively convey the exclusion
of warranty; and each file should have at least the "copyright" line and a
pointer to where the full notice is found.
One line to give the program's name and a brief idea of what it does.
Copyright (C) <year> <name of author>
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 of the License, 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, write to the Free Software Foundation, Inc., 59
Temple Place, Suite 330, Boston, MA 02111-1307 USA
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this when it
starts in an interactive mode:
Gnomovision version 69, Copyright (C) year name of author Gnomovision comes
with ABSOLUTELY NO WARRANTY; for details type 'show w'. This is free
software, and you are welcome to redistribute it under certain conditions;
type 'show c' for details.
The hypothetical commands 'show w' and 'show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may be
called something other than 'show w' and 'show c'; they could even be
mouse-clicks or menu items--whatever suits your program.
You should also get your employer (if you work as a programmer) or your school,
if any, to sign a "copyright disclaimer" for the program, if necessary. Here
is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
'Gnomovision' (which makes passes at compilers) written by James Hacker.
signature of Ty Coon, 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Library General Public
License instead of this License.
"CLASSPATH" EXCEPTION TO THE GPL
Certain source files distributed by Sun Microsystems, Inc. are subject to
the following clarification and special exception to the GPL, but only where
Sun has expressly included in the particular source file's header the words
"Sun designates this particular file as subject to the "Classpath" exception
as provided by Sun in the LICENSE file that accompanied this code."
Linking this library statically or dynamically with other modules is making
a combined work based on this library. Thus, the terms and conditions of
the GNU General Public License cover the whole combination.
As a special exception, the copyright holders of this library give you
permission to link this library with independent modules to produce an
executable, regardless of the license terms of these independent modules,
and to copy and distribute the resulting executable under terms of your
choice, provided that you also meet, for each linked independent module,
the terms and conditions of the license of that module. An independent
module is a module which is not derived from or based on this library. If
you modify this library, you may extend this exception to your version of
the library, but you are not obligated to do so. If you do not wish to do
so, delete this exception statement from your version.
README:
This file should be located at the top of the jdk Mercurial repository.
See http://openjdk.java.net/ for more information about the OpenJDK.
Simple Build Instructions:
1. Download and install a JDK 6 from
http://java.sun.com/javase/downloads/index.jsp
Set the environment variable ALT_BOOTDIR to the location of this JDK 6.
2. Download and install the Binary Plugs for the most recent JDK7 from
http://download.java.net/openjdk/jdk7/
Set the environment variable ALT_BINARY_PLUGS_PATH to the location of
these binary plugs.
3. Either download and install the latest JDK7 from
http://download.java.net/openjdk/jdk7/, or build your own complete
OpenJDK7 by using the top level Makefile in the OpenJDK Mercurial forest.
Set the environment variable ALT_JDK_IMPORT_PATH to the location of
this latest JDK7 or OpenJDK7 build.
4. Check the sanity of doing a build with the current machine:
cd make && gnumake sanity
See README-builds.html if you run into problems.
5. Do a partial build of the jdk:
cd make && gnumake all
6. Construct the images:
cd make && gnumake images
The resulting JDK image should be found in build/*/j2sdk-image
此差异已折叠。
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head> <title>OpenJDK README</title> </head>
<!-- ====================================================== -->
<hr noshade="noshade" size="3">
<center>
<h1>OpenJDK README</h1>
</center>
<!-- ------------------------------------------------------ -->
<hr noshade="noshade" size="3">
<h2>TBD</h2>
<h2>Building the OpenJDK</h2>
<p>
Refer to <a href="README-builds.html">the OpenJDK Build README</a>
for build instructions.
<!-- ====================================================== -->
<hr noshade="noshade" size="3">
</body>
</html>
此差异已折叠。
......@@ -193,7 +193,7 @@ build-jar: $(UNSIGNED_DIR)/sunjce_provider.jar
$(UNSIGNED_DIR)/sunjce_provider.jar: build $(JCE_MANIFEST_FILE)
$(prep-target)
$(BOOT_JAR_CMD) cmf $(JCE_MANIFEST_FILE) $@ $(JAR_DIRS) \
$(JAR_JFLAGS)
$(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
......@@ -253,7 +253,7 @@ endif
@$(CD) $(OBFUS_DIR); $(java-vm-cleanup)
$(BOOT_JAR_CMD) cmf $(JCE_MANIFEST_FILE) $@ \
-C $(OBFUS_DIR)/build com \
$(JAR_JFLAGS)
$(BOOT_JAR_JFLAGS)
$(sign-target)
@$(java-vm-cleanup)
......
#
# Copyright 2002-2006 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2002-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -71,7 +71,7 @@ $(IMJAR): $(FILES_class) $(FILES_copy) $(PROVIDER_CONF_FILE)
$(BOOT_JAR_CMD) -cf $@ \
-C $(CLASSDESTDIR) com \
-C $(CLASSDESTDIR) $(SERVICESDIR) \
$(JAR_JFLAGS)
$(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
clean::
......
#
# Copyright 2002-2006 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2002-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -71,7 +71,7 @@ $(IMJAR): $(FILES_class) $(FILES_copy) $(PROVIDER_CONF_FILE)
$(BOOT_JAR_CMD) -cf $@ \
-C $(CLASSDESTDIR) com \
-C $(CLASSDESTDIR) $(SERVICESDIR) \
$(JAR_JFLAGS)
$(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
clean::
......
#
# Copyright 2003-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2003-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......
#
# Copyright 2000-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2000-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......
#
# Copyright 1998-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1998-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -46,7 +46,7 @@ $(BUILDTOOL_JAR_FILE): $(BUILDTOOL_MANIFEST_FILE) \
-sourcepath $(BUILDTOOL_SOURCE_ROOT) $(BUILDTOOL_MAIN_SOURCE_FILE)
$(BOOT_JAR_CMD) cfm $@ $(BUILDTOOL_MANIFEST_FILE) \
-C $(BUILDTOOLCLASSDIR) $(PKGDIR) \
$(JAR_JFLAGS) || $(RM) $@
$(BOOT_JAR_JFLAGS) || $(RM) $@
@$(java-vm-cleanup)
# Printing out a build tool information line
......
......@@ -86,18 +86,22 @@ HPIS = native
#
# Default optimization
#
CC_HIGHEST_OPT = -O3
CC_HIGHER_OPT = -O3
CC_LOWER_OPT = -O2
CC_NO_OPT =
ifeq ($(PRODUCT), java)
_OPT = $(CC_HIGHER_OPT)
else
_OPT = $(CC_LOWER_OPT)
CPPFLAGS_DBG += -DLOGGING
ifndef OPTIMIZATION_LEVEL
ifeq ($(PRODUCT), java)
OPTIMIZATION_LEVEL = HIGHER
else
OPTIMIZATION_LEVEL = LOWER
endif
endif
CC_OPT/NONE =
CC_OPT/LOWER = -O2
CC_OPT/HIGHER = -O3
CC_OPT/HIGHEST = -O3
CC_OPT = $(CC_OPT/$(OPTIMIZATION_LEVEL))
# For all platforms, do not omit the frame pointer register usage.
# We need this frame pointer to make it easy to walk the stacks.
# This should be the default on X86, but ia64 and amd64 may not have this
......@@ -112,18 +116,6 @@ LDFLAGS_COMMON_sparc += -m32 -mcpu=v9
CFLAGS_REQUIRED = $(CFLAGS_REQUIRED_$(ARCH))
LDFLAGS_COMMON += $(LDFLAGS_COMMON_$(ARCH))
# Add in platform specific optimizations for all opt levels
CC_HIGHEST_OPT += $(_OPT_$(ARCH))
CC_HIGHER_OPT += $(_OPT_$(ARCH))
CC_LOWER_OPT += $(_OPT_$(ARCH))
# If NO_OPTIMIZATIONS is defined in the environment, turn all optimzations off
ifdef NO_OPTIMIZATIONS
CC_HIGHEST_OPT = $(CC_NO_OPT)
CC_HIGHER_OPT = $(CC_NO_OPT)
CC_LOWER_OPT = $(CC_NO_OPT)
endif
#
# Selection of warning messages
#
......@@ -162,19 +154,19 @@ ifeq ($(FASTDEBUG), true)
endif
endif
CFLAGS_OPT = $(POPT)
CFLAGS_OPT = $(CC_OPT)
CFLAGS_DBG = $(DEBUG_FLAG)
CFLAGS_COMMON += $(CFLAGS_REQUIRED)
CXXFLAGS_COMMON = $(GLOBAL_KPIC) -DCC_NOEX $(GCC_WARNINGS)
CXXFLAGS_OPT = $(POPT)
CXXFLAGS_OPT = $(CC_OPT)
CXXFLAGS_DBG = $(DEBUG_FLAG)
CXXFLAGS_COMMON += $(CFLAGS_REQUIRED)
# FASTDEBUG: Optimize the code in the -g versions, gives us a faster debug java
ifeq ($(FASTDEBUG), true)
CFLAGS_DBG += $(CC_LOWER_OPT)
CXXFLAGS_DBG += $(CC_LOWER_OPT)
CFLAGS_DBG += $(CC_OPT/LOWER)
CXXFLAGS_DBG += $(CC_OPT/LOWER)
endif
CPPFLAGS_COMMON = -D$(ARCH) -DARCH='"$(ARCH)"' -DLINUX $(VERSION_DEFINES) \
......@@ -186,6 +178,9 @@ endif
CPPFLAGS_OPT =
CPPFLAGS_DBG = -DDEBUG
ifneq ($(PRODUCT), java)
CPPFLAGS_DBG += -DLOGGING
endif
ifdef LIBRARY
# Libraries need to locate other libraries at runtime, and you can tell
......
......@@ -86,15 +86,16 @@ HPIS = native
#
# Java default optimization (-x04/-O2) etc. Applies to the VM.
#
ifeq ($(PRODUCT), java)
_OPT = $(CC_HIGHER_OPT)
else
_OPT = $(CC_LOWER_OPT)
CPPFLAGS_DBG += -DLOGGING -DDBINFO
ifndef OPTIMIZATION_LEVEL
ifeq ($(PRODUCT), java)
OPTIMIZATION_LEVEL = HIGHER
else
OPTIMIZATION_LEVEL = LOWER
endif
endif
#
# If -Xa is in CFLAGS_COMMON it will end up ahead of $(POPT) for the
# If -Xa is in CFLAGS_COMMON it will end up ahead of $(CC_OPT) for the
# optimized build, and that ordering of the flags completely freaks
# out cc. Hence, -Xa is instead in each CFLAGS variant.
#
......@@ -123,8 +124,8 @@ endif
#
# Debug flag for C and C++ compiler
#
CFLAGS_DEBUG_OPTION=-g
CXXFLAGS_DEBUG_OPTION=-g
CFLAGS_DEBUG_OPTION = -g $(CC_OPT/NONE)
CXXFLAGS_DEBUG_OPTION = -g $(CXX_OPT/NONE)
# Turn off -g if we are doing tcov build
ifdef TCOV_BUILD
......@@ -142,9 +143,8 @@ endif
# Performance/size of files should be about the same, maybe smaller.
#
ifeq ($(FASTDEBUG), true)
CC_FASTDEBUG_OPT = $(CC_LOWER_OPT)
CFLAGS_DEBUG_OPTION = -g $(CC_FASTDEBUG_OPT)
CXXFLAGS_DEBUG_OPTION = -g0 $(CC_FASTDEBUG_OPT)
CFLAGS_DEBUG_OPTION = -g $(CC_OPT/LOWER)
CXXFLAGS_DEBUG_OPTION = -g0 $(CXX_OPT/LOWER)
endif
CFLAGS_COMMON = -L$(OBJDIR)
......@@ -160,7 +160,7 @@ CFLAGS_COMMON += -errshort=tags
CXXFLAGS_COMMON += -errtags=yes
# Optimization flags
CFLAGS_OPT = $(POPT)
CFLAGS_OPT = $(CC_OPT)
# Debug version flags
CFLAGS_DBG = $(CFLAGS_DEBUG_OPTION)
......@@ -197,7 +197,7 @@ ifeq ($(COMPILER_WARNINGS_FATAL),true)
CXXFLAGS_COMMON += -errwarn=%all
endif
CXXFLAGS_OPT = $(POPT)
CXXFLAGS_OPT = $(CXX_OPT)
CXXFLAGS_DBG = $(CXXFLAGS_DEBUG_OPTION)
CXXFLAGS_COMMON += $(CFLAGS_REQUIRED)
......@@ -267,6 +267,10 @@ CPPFLAGS_COMMON = -D__solaris__ -D$(ARCH_FAMILY)
CPPFLAGS_OPT = -DNDEBUG
CPPFLAGS_DBG = -DDEBUG
ifneq ($(PRODUCT), java)
CPPFLAGS_DBG += -DLOGGING -DDBINFO
endif
ifeq ($(ARCH_FAMILY), i586)
# The macro _LITTLE_ENDIAN needs to be defined the same to avoid the
# Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN
......@@ -410,63 +414,151 @@ endif
# Different "levels" of optimization.
#
ifeq ($(CC_VERSION),gcc)
CC_HIGHEST_OPT = -O3
CC_HIGHER_OPT = -O3
CC_LOWER_OPT = -O2
CC_OPT/NONE =
CC_OPT/LOWER = -O2
CC_OPT/HIGHER = -O3
CC_OPT/HIGHEST = -O3
CXX_OPT/NONE =
CXX_OPT/LOWER = -O2
CXX_OPT/HIGHER = -O3
CXX_OPT/HIGHEST = -O3
CFLAGS_REQUIRED_i586 += -fno-omit-frame-pointer
CFLAGS_REQUIRED_amd64 += -fno-omit-frame-pointer
# Automatic precompiled header option to use (if COMPILE_APPROACH=batch)
# (See Rules.gmk) May need to wait for gcc 5?
AUTOMATIC_PCH_OPTION =
else
# Highest could be -xO5, but indications are that -xO5 should be reserved
# for a per-file use, on sources with known performance impacts.
CC_HIGHEST_OPT = -xO4
CC_HIGHER_OPT = -xO4
CC_LOWER_OPT = -xO2
OPT_LEVEL/LOWER = 2
OPT_LEVEL/HIGHER = 4
OPT_LEVEL/HIGHEST = 4
CC_OPT/NONE =
CC_OPT/LOWER = $(OPT_LEVEL/LOWER:%=-xO%)
CC_OPT/HIGHER = $(OPT_LEVEL/HIGHER:%=-xO%)
CC_OPT/HIGHEST = $(OPT_LEVEL/HIGHEST:%=-xO%)
CXX_OPT/NONE =
CXX_OPT/LOWER = $(OPT_LEVEL/LOWER:%=-xO%)
CXX_OPT/HIGHER = $(OPT_LEVEL/HIGHER:%=-xO%)
CXX_OPT/HIGHEST = $(OPT_LEVEL/HIGHEST:%=-xO%)
# We need stack frames at all times
USE_XKEEPFRAME_OPTION = false
ifeq ($(USE_XKEEPFRAME_OPTION),true)
# Unknown spelling on this option at this time (Maybe in SS13?)
CC_XKEEPFRAME_OPTIONS = -xkeepframe
CXX_XKEEPFRAME_OPTIONS = -xkeepframe
else
# On X86, make sure tail call optimization is off
# The z and y are the tail call optimizations.
ifeq ($(ARCH_FAMILY), i586)
ifeq ($(shell $(EXPR) $(CC_VER) \> 5.8), 1)
# Somehow, tail call optimization is creeping in.
# Make sure it is off.
# WARNING: These may cause compiler warnings about duplicate -O options
CC_XKEEPFRAME_OPTIONS += -Wu,-O$(OPT_LEVEL/$(OPTIMIZATION_LEVEL))~yz
CXX_XKEEPFRAME_OPTIONS += -Qoption ube -O$(OPT_LEVEL/$(OPTIMIZATION_LEVEL))~yz
endif
endif
# On i586 we need to tell the code generator to ALWAYS use a
# frame pointer.
ifeq ($(ARCH_FAMILY), i586)
# Note that in 5.7, this is done with -xregs=no%frameptr
ifeq ($(CC_VER), 5.5)
# It's not exactly clear when this optimization kicks in, the
# current assumption is -xO4 or greater and for C++ with
# the -features=no%except option and -xO4 and greater.
# Bottom line is, we ALWAYS want a frame pointer!
CC_XKEEPFRAME_OPTIONS += -Wu,-Z~B
CXX_XKEEPFRAME_OPTIONS += -Qoption ube -Z~B
endif
ifeq ($(shell $(EXPR) $(CC_VER) \> 5.6), 1)
# Do NOT use frame pointer register as a general purpose opt register
CC_OPT/NONE += -xregs=no%frameptr
CXX_OPT/NONE += -xregs=no%frameptr
CC_XKEEPFRAME_OPTIONS += -xregs=no%frameptr
CXX_XKEEPFRAME_OPTIONS += -xregs=no%frameptr
endif
endif
# Optimizer for sparc needs to be told not to do certain things
# related to frames or save instructions.
ifeq ($(ARCH_FAMILY), sparc)
# Do not use save instructions instead of add instructions
# This was an optimization starting in SC5.0 that made it hard for us to
# find the "save" instruction (which got turned into an "add")
CC_XKEEPFRAME_OPTIONS += -Wc,-Qrm-s
CXX_XKEEPFRAME_OPTIONS += -Qoption cg -Qrm-s
# Don't allow tail call code optimization. Started in SC5.0.
# We don't like code of this form:
# save
# <code>
# call foo
# restore
# because we can't tell if the method will have a stack frame
# and register windows or not.
CC_XKEEPFRAME_OPTIONS += -Wc,-Qiselect-T0
CXX_XKEEPFRAME_OPTIONS += -Qoption cg -Qiselect-T0
endif
endif
# Extra options used with HIGHEST
#
# WARNING: Use of _OPT=$(CC_HIGHEST_OPT) in your Makefile needs to be
# WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be
# done with care, there are some assumptions below that need to
# be understood about the use of pointers, and IEEE behavior.
#
# Use non-standard floating point mode (not IEEE 754)
CC_HIGHEST_OPT += -fns
CC_HIGHEST_EXTRAS += -fns
# Do some simplification of floating point arithmetic (not IEEE 754)
CC_HIGHEST_OPT += -fsimple
CC_HIGHEST_EXTRAS += -fsimple
# Use single precision floating point with 'float'
CC_HIGHEST_OPT += -fsingle
CC_HIGHEST_EXTRAS += -fsingle
# Assume memory references via basic pointer types do not alias
# (Source with excessing pointer casting and data access with mixed
# pointer types are not recommended)
CC_HIGHEST_OPT += -xalias_level=basic
CC_HIGHEST_EXTRAS += -xalias_level=basic
# Use intrinsic or inline versions for math/std functions
# (If you expect perfect errno behavior, do not use this)
CC_HIGHEST_OPT += -xbuiltin=%all
CC_HIGHEST_EXTRAS += -xbuiltin=%all
# Loop data dependency optimizations (need -xO3 or higher)
CC_HIGHEST_OPT += -xdepend
CC_HIGHEST_EXTRAS += -xdepend
# Pointer parameters to functions do not overlap
# (Similar to -xalias_level=basic usage, but less obvious sometimes.
# If you pass in multiple pointers to the same data, do not use this)
CC_HIGHEST_OPT += -xrestrict
CC_HIGHEST_EXTRAS += -xrestrict
# Inline some library routines
# (If you expect perfect errno behavior, do not use this)
CC_HIGHEST_OPT += -xlibmil
CC_HIGHEST_EXTRAS += -xlibmil
# Use optimized math routines
# (If you expect perfect errno behavior, do not use this)
# Can cause undefined external on Solaris 8 X86 on __sincos, removing for now
# CC_HIGHEST_OPT += -xlibmopt
# CC_HIGHEST_EXTRAS += -xlibmopt
ifeq ($(ARCH_FAMILY), sparc)
# Assume at most 8byte alignment, raise SIGBUS on error
### Presents an ABI issue with customer JNI libs?
####CC_HIGHEST_OPT += -xmemalign=8s
####CC_HIGHEST_EXTRAS += -xmemalign=8s
# Automatic prefetch instructions, explicit prefetch macros
CC_HIGHEST_OPT += -xprefetch=auto,explicit
CC_HIGHEST_EXTRAS += -xprefetch=auto,explicit
# Pick ultra as the chip to optimize to
CC_HIGHEST_OPT += -xchip=ultra
CC_HIGHEST_EXTRAS += -xchip=ultra
endif
ifeq ($(ARCH), i586)
# Pick pentium as the chip to optimize to
CC_HIGHEST_OPT += -xchip=pentium
CC_HIGHEST_EXTRAS += -xchip=pentium
endif
ifdef LIBRARY
# The Solaris CBE (Common Build Environment) requires that the use
......@@ -476,9 +568,6 @@ else
CFLAGS_REQUIRED_sparcv9 += -xregs=no%appl
endif
ifeq ($(shell $(EXPR) $(CC_VER) \> 5.6), 1)
# Do NOT use the frame pointer register as a general purpose opt register
CFLAGS_REQUIRED_i586 += -xregs=no%frameptr
CFLAGS_REQUIRED_amd64 += -xregs=no%frameptr
# We MUST allow data alignment of 4 for sparc V8 (32bit)
# Presents an ABI issue with customer JNI libs? We must be able to
# to handle 4byte aligned objects? (rare occurance, but possible?)
......@@ -492,77 +581,28 @@ else
# Automatic precompiled header option to use (if COMPILE_APPROACH=batch)
# (See Rules.gmk) The SS11 -xpch=auto* options appear to be broken.
AUTOMATIC_PCH_OPTION =
# Add in keep frame options
CC_OPT/LOWER += $(CC_XKEEPFRAME_OPTIONS)
CC_OPT/HIGHER += $(CC_XKEEPFRAME_OPTIONS)
CC_OPT/HIGHEST += $(CC_XKEEPFRAME_OPTIONS)
CXX_OPT/LOWER += $(CXX_XKEEPFRAME_OPTIONS)
CXX_OPT/HIGHER += $(CXX_XKEEPFRAME_OPTIONS)
CXX_OPT/HIGHEST += $(CXX_XKEEPFRAME_OPTIONS)
# Add in highest optimization settings
CC_OPT/HIGHEST += $(CC_HIGHEST_EXTRAS)
CXX_OPT/HIGHEST += $(CC_HIGHEST_EXTRAS)
endif
CC_NO_OPT =
# If NO_OPTIMIZATIONS is defined in the environment, turn all optimzations off
ifdef NO_OPTIMIZATIONS
CC_HIGHEST_OPT = $(CC_NO_OPT)
CC_HIGHER_OPT = $(CC_NO_OPT)
CC_LOWER_OPT = $(CC_NO_OPT)
endif
# Default optimization settings based on level.
CC_OPT = $(CC_OPT/$(OPTIMIZATION_LEVEL))
CXX_OPT = $(CXX_OPT/$(OPTIMIZATION_LEVEL))
# Flags required all the time
CFLAGS_REQUIRED = $(CFLAGS_REQUIRED_$(ARCH))
# Add processor specific options for optimizations
CC_HIGHEST_OPT += $(_OPT_$(ARCH))
CC_HIGHER_OPT += $(_OPT_$(ARCH))
CC_LOWER_OPT += $(_OPT_$(ARCH))
# Secret compiler optimization options that should be in the above macros
# but since they differ in format from C to C++, are added into the C or
# C++ specific macros for compiler flags.
#
# On i586 we need to tell the code generator to ALWAYS use a
# frame pointer.
ifeq ($(ARCH_FAMILY), i586)
# Note that in 5.7, this is done with -xregs=no%frameptr
ifeq ($(CC_VER), 5.5)
# It's not exactly clear when this optimization kicks in, the
# current assumption is -xO4 or greater and for C++ with
# the -features=no%except option and -xO4 and greater.
# Bottom line is, we ALWAYS want a frame pointer!
CXXFLAGS_OPT += -Qoption ube -Z~B
CFLAGS_OPT += -Wu,-Z~B
ifeq ($(FASTDEBUG), true)
CXXFLAGS_DBG += -Qoption ube -Z~B
CFLAGS_DBG += -Wu,-Z~B
endif
endif
endif
#
# Optimizer for sparc needs to be told not to do certain things
# related to frames or save instructions.
ifeq ($(ARCH_FAMILY), sparc)
# NOTE: Someday the compilers will provide a high-level option for this.
# Use save instructions instead of add instructions
# This was an optimization starting in SC5.0 that made it hard for us to
# find the "save" instruction (which got turned into an "add")
CXXFLAGS_OPT += -Qoption cg -Qrm-s
CFLAGS_OPT += -Wc,-Qrm-s
ifeq ($(FASTDEBUG), true)
CXXFLAGS_DBG += -Qoption cg -Qrm-s
CFLAGS_DBG += -Wc,-Qrm-s
endif
#
# NOTE: Someday the compilers will provide a high-level option for this.
# Don't allow tail call code optimization. Started in SC5.0.
# We don't like code of this form:
# save
# <code>
# call foo
# restore
# because we can't tell if the method will have a stack frame
# and register windows or not.
CXXFLAGS_OPT += -Qoption cg -Qiselect-T0
CFLAGS_OPT += -Wc,-Qiselect-T0
ifeq ($(FASTDEBUG), true)
CXXFLAGS_DBG += -Qoption cg -Qiselect-T0
CFLAGS_DBG += -Wc,-Qiselect-T0
endif
endif
#
# Path and option to link against the VM, if you have to. Note that
# there are libraries that link against only -ljava, but they do get
......
......@@ -84,6 +84,15 @@ EXTRA_LFLAGS += /LIBPATH:$(DXSDK_LIB_PATH)
#
# Default optimization
#
ifndef OPTIMIZATION_LEVEL
ifeq ($(PRODUCT), java)
OPTIMIZATION_LEVEL = HIGHER
else
OPTIMIZATION_LEVEL = LOWER
endif
endif
ifeq ($(CC_VERSION),msvc)
# Visual Studio .NET 2003 or VS2003 compiler option definitions:
# -O1 Favors reduced size over speed (-Og -Os -Oy -Ob2 -Gs -GF -Gy)
......@@ -113,21 +122,28 @@ ifeq ($(CC_VERSION),msvc)
# NOTE: With VC6, -Ox, -O1, and -O2 used -Ob1, not -Ob2.
# NOTE: With VC6, -O1 and -O2 used -Gf, not -GF.
#
CC_OPT/NONE = -Od
CC_OPT/LOWER = -O2
CC_OPT/HIGHER = -O3
CC_OPT/HIGHEST = -O3
ifeq ($(COMPILER_VERSION), VC6)
# VC6 (6.2) msvc compiler (the way Tiger and early Mustang were built)
# Automatic precompiled header option to use (if COMPILE_APPROACH=batch)
AUTOMATIC_PCH_OPTION =
GX_OPTION = -GX
ifeq ($(ARCH_DATA_MODEL), 32)
CC_HIGHEST_OPT = -Ox -Gy -Os -GB
CC_HIGHER_OPT = -Ox -Gy -Os -GB
CC_LOWER_OPT = -Ox -Gy -Os -GB
CC_OPT/HIGHEST = -Ox -Gy -Os -GB
CC_OPT/HIGHER = -Ox -Gy -Os -GB
CC_OPT/LOWER = -Ox -Gy -Os -GB
else
CC_HIGHEST_OPT = -Ox -Gy -Op
CC_HIGHER_OPT = -Ox -Gy -Op
CC_LOWER_OPT = -Ox -Gy -Op
CC_OPT/HIGHEST = -Ox -Gy -Op
CC_OPT/HIGHER = -Ox -Gy -Op
CC_OPT/LOWER = -Ox -Gy -Op
endif
endif
ifeq ($(COMPILER_VERSION), VS2003)
# Automatic precompiled header option to use (if COMPILE_APPROACH=batch)
AUTOMATIC_PCH_OPTION = -YX
......@@ -135,53 +151,45 @@ ifeq ($(CC_VERSION),msvc)
GX_OPTION = -GX
ifeq ($(ARCH_DATA_MODEL), 32)
# Lowered opt level to try and reduce footprint, dll size especially.
# Was: CC_HIGHEST_OPT = -O2 -G6
# Was: CC_HIGHER_OPT = -O2
CC_HIGHEST_OPT = -O2
CC_HIGHER_OPT = -O1
CC_LOWER_OPT = -O1
# Was: CC_OPT/HIGHEST = -O2 -G6
# Was: CC_OPT/HIGHER = -O2
CC_OPT/HIGHEST = -O2
CC_OPT/HIGHER = -O1
CC_OPT/LOWER = -O1
else
CC_HIGHEST_OPT = -O2 -Op
CC_HIGHER_OPT = -O2 -Op
CC_LOWER_OPT = -O1 -Op
CC_OPT/HIGHEST = -O2 -Op
CC_OPT/HIGHER = -O2 -Op
CC_OPT/LOWER = -O1 -Op
endif
endif
ifeq ($(COMPILER_VERSION), VS2005)
# Automatic precompiled header option to use (if COMPILE_APPROACH=batch)
AUTOMATIC_PCH_OPTION =
# VS2005 compiler, only with Platform SDK right now?
GX_OPTION = -EHsc
ifeq ($(ARCH_DATA_MODEL), 32)
CC_HIGHEST_OPT = -O2
CC_HIGHER_OPT = -O1
CC_LOWER_OPT = -O1
CC_OPT/HIGHEST = -O2
CC_OPT/HIGHER = -O1
CC_OPT/LOWER = -O1
else
CC_HIGHEST_OPT = -O2
CC_HIGHER_OPT = -O1
CC_LOWER_OPT = -O1
CC_OPT/HIGHEST = -O2
CC_OPT/HIGHER = -O1
CC_OPT/LOWER = -O1
endif
endif
CC_NO_OPT = -Od
else # CC_VERSION
# GCC not supported, but left for historical reference...
CC_HIGHEST_OPT = -O3
CC_HIGHER_OPT = -O2
CC_LOWER_OPT = -O2
CC_NO_OPT =
endif
CC_OPT/NONE =
CC_OPT/LOWER = -O2
CC_OPT/HIGHER = -O2
CC_OPT/HIGHEST = -O3
# If NO_OPTIMIZATIONS is defined in the environment, turn all optimzations off
ifdef NO_OPTIMIZATIONS
CC_HIGHEST_OPT = $(CC_NO_OPT)
CC_HIGHER_OPT = $(CC_NO_OPT)
CC_LOWER_OPT = $(CC_NO_OPT)
endif
ifeq ($(PRODUCT), java)
_OPT = $(CC_HIGHER_OPT)
else
_OPT = $(CC_LOWER_OPT)
endif
CC_OPT = $(CC_OPT/$(OPTIMIZATION_LEVEL))
# Select the runtime support library carefully, need to be consistent
#
......@@ -233,7 +241,7 @@ ifeq ($(CC_VERSION),msvc)
# Use static link for the C++ runtime (so msvcp71.dll not needed)
#
CFLAGS_COMMON += -Zi -nologo
CFLAGS_OPT = $(POPT)
CFLAGS_OPT = $(CC_OPT)
CFLAGS_DBG = -Od $(MS_RUNTIME_DEBUG_OPTION)
# Starting from VS2005 the wchar_t is handled as a built-in C/C++ data type
......
......@@ -451,7 +451,7 @@ vpath %.$(OBJECT_SUFFIX) $(OBJDIR)
# namely jni.h, jvm.h, and jni_utils.h, plus their platform-specific
# relatives.
#
VPATH.h = $(PLATFORM_SRC)/javavm/export$(CLASSPATH_SEPARATOR)$(SHARE_SRC)/javavm/export$(CLASSPATH_SEPARATOR)$(SHARE_SRC)/javavm/include$(CLASSPATH_SEPARATOR)$(PLATFORM_SRC)/javavm/include
VPATH.h = $(PLATFORM_SRC)/javavm/export$(CLASSPATH_SEPARATOR)$(SHARE_SRC)/javavm/export
vpath %.h $(VPATH.h)
#
......@@ -482,11 +482,6 @@ PKGDIR = $(subst .,/,$(PACKAGE))
#
include $(JDK_MAKE_SHARED_DIR)/Defs-java.gmk
#
# Set opt level to ALT_OPT if set otherwise _OPT
#
POPT = $(_OPT$(ALT_OPT))$(ALT_OPT)
#
# Convenient macros
#
......@@ -709,7 +704,20 @@ endif
# Install of imported file (JDK_IMPORT_PATH, or some other external location)
define install-import-file
@$(ECHO) "ASSEMBLY_IMPORT: $@"
$(install-file)
$(prep-target)
$(CP) $< $@
@if [ "$(PLATFORM)" = "linux" -a "$(@F)" = "libjvm.so" ] ; then \
if [ -x /usr/sbin/selinuxenabled ] ; then \
/usr/sbin/selinuxenabled; \
if [ $$? = 0 ] ; then \
$(ECHO) "/usr/bin/chcon -t textrel_shlib_t $@"; \
/usr/bin/chcon -t textrel_shlib_t $@; \
if [ $$? != 0 ]; then \
echo "ERROR: Cannot chcon $@"; \
fi; \
fi; \
fi; \
fi
endef
.PHONY: all build clean clobber
#
# Copyright 2004-2006 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2004-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -251,7 +251,7 @@ $(DEMO_JAR): \
@$(DEMO_JAVAC_INPUT)
$(BOOT_JAR_CMD) -cfm $@ $(DEMO_MANIFEST) \
-C $(DEMO_JAR_IMAGE) . \
$(JAR_JFLAGS)
$(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
endif
......@@ -317,7 +317,11 @@ bundles: $(DEMO_BUILD_SRCZIP)
# Applets are special, no jar file, no src.zip, everything expanded.
ifdef DEMO_IS_APPLET
@$(ECHO) "Expanding jar file into demos area at $(DEMO_DESTDIR)"
( $(CD) $(DEMO_DESTDIR) && $(BOOT_JAR_CMD) -xfv $(DEMONAME).jar && $(RM) -r META-INF $(DEMONAME).jar )
( $(CD) $(DEMO_DESTDIR) && \
$(BOOT_JAR_CMD) -xfv $(DEMONAME).jar \
$(BOOT_JAR_JFLAGS) && \
$(RM) -r META-INF $(DEMONAME).jar && \
$(java-vm-cleanup) )
@( $(CD) $(DEMO_DESTDIR) && $(java-vm-cleanup) )
@$(ECHO) "Expanding source into demos area at $(DEMO_DESTDIR)"
( $(CD) $(DEMO_DESTDIR) && $(UNZIP) -o src.zip && $(RM) src.zip )
......
#
# Copyright 1995-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1995-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -238,7 +238,7 @@ else # PLATFORM
#
$(ACTUAL_LIBRARY):: $(COMPILE_FILES_o) $(FILES_m) $(FILES_reorder)
@$(prep-target)
@$(ECHO) "STATS: LIBRARY=$(LIBRARY), PRODUCT=$(PRODUCT), _OPT=$(_OPT)"
@$(ECHO) "STATS: LIBRARY=$(LIBRARY), PRODUCT=$(PRODUCT), OPTIMIZATION_LEVEL=$(OPTIMIZATION_LEVEL)"
@$(ECHO) "Rebuilding $@ because of $?"
ifeq ($(LIBRARY), fdlibm)
$(AR) -r $@ $(FILES_o)
......
......@@ -63,15 +63,6 @@ endif
JTG_DOCS = $(JDK_TOPDIR)/src/solaris/doc
# Choose the right set of documents for the images
ifdef OPENJDK
SHARE_JDK_DOC_SRC = $(JDK_TOPDIR)/make
SHARE_JRE_DOC_SRC = $(JDK_TOPDIR)/make
else
SHARE_JDK_DOC_SRC = $(CLOSED_SHARE_SRC)/doc/jdk
SHARE_JRE_DOC_SRC = $(CLOSED_SHARE_SRC)/doc/jre
endif
#We use this for man page header
jdkversion := $(JDK_MAJOR_VERSION).$(JDK_MINOR_VERSION).$(JDK_MICRO_VERSION)
......@@ -81,13 +72,20 @@ ifeq ($(PLATFORM), windows)
endif
# The base names of all the license and document files for the jdk and jre
# (These files get placed in the jdk and jre install images)
ifdef OPENJDK
# Where to find these files
SHARE_JDK_DOC_SRC = $(JDK_TOPDIR)
SHARE_JRE_DOC_SRC = $(JDK_TOPDIR)
# Same files for jdk and jre, no name changes
LICENSE_DOCLIST_JDK = LICENSE ASSEMBLY_EXCEPTION
LICENSE_DOCLIST_JRE = LICENSE ASSEMBLY_EXCEPTION
OTHER_DOCLIST_JDK = README.html THIRD_PARTY_README
OTHER_DOCLIST_JRE = README.html THIRD_PARTY_README
OTHER_DOCLIST_JDK = THIRD_PARTY_README
OTHER_DOCLIST_JRE = THIRD_PARTY_README
else
# Where to find these files
SHARE_JDK_DOC_SRC = $(CLOSED_SHARE_SRC)/doc/jdk
SHARE_JRE_DOC_SRC = $(CLOSED_SHARE_SRC)/doc/jre
# Select the pre-release or FCS license version based on the build milestone.
LICENSE_VERSION=.pre
ifeq ($(MILESTONE), fcs)
......@@ -662,7 +660,7 @@ $(RES_JAR_ARGLIST): $(RES_JAR_FILELIST)
$(RESOURCES_JAR): $(RES_JAR_ARGLIST) $(JAR_MANIFEST_FILE)
$(prep-target)
$(BOOT_JAR_CMD) c0mf $(JAR_MANIFEST_FILE) $@ \
@$(RES_JAR_ARGLIST) $(JAR_JFLAGS)
@$(RES_JAR_ARGLIST) $(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
# Create jsse.jar containing SunJSSE implementation classes
......@@ -671,7 +669,7 @@ $(JSSE_JAR): $(JAR_MANIFEST_FILE)
$(prep-target)
$(BOOT_JAR_CMD) c0mf $(JAR_MANIFEST_FILE) $@ \
$(JSSE_CLASSES_DIRS:%=-C $(CLASSBINDIR) %) \
$(JAR_JFLAGS)
$(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
# Create sec-bin.zip
......@@ -721,7 +719,7 @@ $(RT_JAR_ARGLIST): $(RT_JAR_FILELIST)
$(RT_JAR): $(RT_JAR_ARGLIST) $(JAR_MANIFEST_FILE)
$(prep-target)
$(BOOT_JAR_CMD) c0mf $(JAR_MANIFEST_FILE) $@ \
@$(RT_JAR_ARGLIST) $(JAR_JFLAGS)
@$(RT_JAR_ARGLIST) $(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
# Meta-index construction to make core class loaders lazier
......@@ -955,7 +953,7 @@ initial-image-jdk:: initial-image-jdk-setup \
@#
$(BOOT_JAR_CMD) c0f $(LIBDIR)/tools.jar $(addprefix \
-C $(CLASSBINDIR) , $(TOOLS)) \
$(JAR_JFLAGS)
$(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
$(CP) $(LIBDIR)/tools.jar $(JDK_IMAGE_DIR)/lib/tools.jar
@#
......@@ -968,7 +966,7 @@ initial-image-jdk:: initial-image-jdk-setup \
-Acom.sun.tools.javac.sym.Dest=$(OUTPUTDIR)/symbols/META-INF/sym/rt.jar \
$(CORE_PKGS) $(NON_CORE_PKGS) $(EXCLUDE_PROPWARN_PKGS)
$(BOOT_JAR_CMD) c0f $(LIBDIR)/ct.sym \
-C $(OUTPUTDIR)/symbols META-INF $(JAR_JFLAGS)
-C $(OUTPUTDIR)/symbols META-INF $(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
$(CP) $(LIBDIR)/ct.sym $(JDK_IMAGE_DIR)/lib/ct.sym
@#
......@@ -1132,11 +1130,11 @@ endef
COMPARE_FILTER = | $(EGREP) -v /fastdebug/ | $(EGREP) -v /demo/ | $(EGREP) -v /sample/
# If a previuous image is provided, no need to install it.
ifdef PREVIOUS_JDK_IMAGE
ifdef PREVIOUS_RELEASE_IMAGE
# Just use the pre-installed images
PREV_JRE_IMAGE_DIR=$(PREVIOUS_JDK_IMAGE)/jre
PREV_JDK_IMAGE_DIR=$(PREVIOUS_JDK_IMAGE)
PREV_JRE_IMAGE_DIR=$(PREVIOUS_RELEASE_IMAGE)/jre
PREV_JDK_IMAGE_DIR=$(PREVIOUS_RELEASE_IMAGE)
else
......
#
# Copyright 2001-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2001-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -70,7 +70,6 @@ sanity-base: pre-sanity \
sane-compiler \
sane-cacerts \
sane-ant_version \
sane-findbugs_version \
sane-zip_version \
sane-msvcrt_path
......
......@@ -185,7 +185,8 @@ endef # import-binary-plug-file
define import-binary-plug-classes
@$(MKDIR) -p $(CLASSDESTDIR)
@$(CAT) $1 | $(SED) -e 's/^/PLUG IMPORT: /'
($(CD) $(CLASSDESTDIR) && $(BOOT_JAR_CMD) xf $(PLUG_IMPORT_JARFILE) @$1)
($(CD) $(CLASSDESTDIR) && $(BOOT_JAR_CMD) xf $(PLUG_IMPORT_JARFILE) @$1 $(BOOT_JAR_JFLAGS) )
($(CD) $(CLASSDESTDIR) && $(java-vm-cleanup) )
endef # import-binary-plug-classes
# Import specific area classes (the classes are always created)
......@@ -275,7 +276,8 @@ $(PLUG_EXPORT_JARFILE): $(PLUG_TEMPDIR)/all.clist $(PLUG_TEMPDIR)/all.jargs
@$(prep-target)
@$(ECHO) "PLUG EXPORT: $(@F)"
@$(CAT) $(PLUG_TEMPDIR)/all.clist | $(SED) -e 's/^/PLUG EXPORT: /'
$(BOOT_JAR_CMD) cf $@ @$(PLUG_TEMPDIR)/all.jargs
$(BOOT_JAR_CMD) cf $@ @$(PLUG_TEMPDIR)/all.jargs $(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
export-binary-plugs-jar: $(PLUG_EXPORT_JARFILE)
# Export native libraries
......
#
# Copyright 1997-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1997-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -107,8 +107,9 @@ endef
define Unjar
( \
$(MKDIR) -p $1; \
$(ECHO) "( $(CD) $1 && $(BOOT_JAR_CMD) xfv $2 $3 )" ; \
( $(CD) $1 && $(BOOT_JAR_CMD) xfv $2 $3 ) \
$(ECHO) "( $(CD) $1 && $(BOOT_JAR_CMD) xfv $2 $3 $(BOOT_JAR_JFLAGS) )" ; \
( $(CD) $1 && $(BOOT_JAR_CMD) xfv $2 $3 $(BOOT_JAR_JFLAGS) ) && \
( $(CD) $1 && $(java-vm-cleanup) ) \
)
endef
......
......@@ -31,11 +31,8 @@ COMPILER_NAME=Sun Studio
# Sun Studio Compiler settings specific to Solaris
ifeq ($(PLATFORM), solaris)
# FIXUP: Change to SS12 when validated
#COMPILER_VERSION=SS12
#REQUIRED_CC_VER=5.9
COMPILER_VERSION=SS11
REQUIRED_CC_VER=5.8
COMPILER_VERSION=SS12
REQUIRED_CC_VER=5.9
CC = $(COMPILER_PATH)cc
CPP = $(COMPILER_PATH)cc -E
CXX = $(COMPILER_PATH)CC
......
#
# Copyright 2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -190,6 +190,7 @@ ifeq ($(JAVAC_WARNINGS_FATAL), true)
BOOT_JAVACFLAGS += -Werror
endif
BOOT_JAVACFLAGS += -encoding ascii
BOOT_JAR_JFLAGS += $(JAR_JFLAGS)
BOOT_JAVA_CMD = $(BOOTDIR)/bin/java $(JAVA_TOOLS_FLAGS)
BOOT_JAVAC_CMD = $(BOOTDIR)/bin/javac $(JAVAC_JVM_FLAGS) $(BOOT_JAVACFLAGS)
......
#
# Copyright 2005-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2005-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -539,6 +539,8 @@ else
WSCRIPT :=$(call FileExists,$(_WSCRIPT1),$(_WSCRIPT2))
endif
WSCRIPT:=$(call AltCheckSpaces,WSCRIPT)
# batch mode no modal dialogs on errors, please.
WSCRIPT += -B
# CSCRIPT: path to cscript.exe (used in creating install bundles)
ifdef ALT_CSCRIPT
......@@ -561,6 +563,10 @@ else
MSIVAL2 :=$(call FileExists,$(_MSIVAL2_1),$(_MSIVAL2_2))
endif
MSIVAL2:=$(call AltCheckSpaces,MSIVAL2)
# suppress msival2 checks, as it hangs jprt builds
ifdef SKIP_MSIVAL2
MSIVAL2 := $(ECHO)
endif
# LOGOCUB: path to cub file for (used in validating install msi files)
ifdef ALT_LOGOCUB
......
......@@ -279,9 +279,6 @@ PROMOTED_BUILD_LATEST = latest
PROMOTED_BUILD_BASEDIR = $(PROMOTED_RE_AREA)/$(PROMOTED_BUILD_LATEST)
PROMOTED_BUILD_BINARIES = $(PROMOTED_BUILD_BASEDIR)/binaries
# OPT: Changes what the optimizations settings (in _OPT)
POPT = $(_OPT$(ALT_OPT))$(ALT_OPT)
# PARALLEL_COMPILE_JOBS: is the number of compiles done in parallel.
# If the user sets ALT_PARALLEL_COMPILE_JOBS, then COMPILE_APPROACH is set
# to parallel.
......@@ -355,30 +352,6 @@ else
HOTSPOT_DOCS_IMPORT_PATH :=$(call DirExists,$(HOTSPOT_IMPORT_PATH)/docs,$(PROMOTED_BUILD_BASEDIR)/docs,/NO_DOCS_DIR)
endif
# PREVIOUS_JDK_FILE: filename of install bundle for previous JDK
ifdef ALT_PREVIOUS_JDK_FILE
PREVIOUS_JDK_FILE =$(ALT_PREVIOUS_JDK_FILE)
else
PREVIOUS_JDK_FILE = jdk-$(PREVIOUS_JDK_UNDERSCORE_VERSION)-$(PLATFORM)-$(ARCH)$(BUNDLE_FILE_SUFFIX)
endif
export PREVIOUS_JDK_FILE
PREVIOUS_JDK_FILE:=$(call AltCheckSpaces,PREVIOUS_JDK_FILE)
PREVIOUS_JDK_FILE:=$(call AltCheckValue,PREVIOUS_JDK_FILE)
# PREVIOUS_JRE_FILE: filename of install bundle for previous JRE
ifdef ALT_PREVIOUS_JRE_FILE
PREVIOUS_JRE_FILE =$(ALT_PREVIOUS_JRE_FILE)
else
PREVIOUS_JRE_FILE = jre-$(PREVIOUS_JDK_UNDERSCORE_VERSION)-$(PLATFORM)-$(ARCH)$(BUNDLE_FILE_SUFFIX)
endif
export PREVIOUS_JRE_FILE
PREVIOUS_JRE_FILE:=$(call AltCheckSpaces,PREVIOUS_JRE_FILE)
PREVIOUS_JRE_FILE:=$(call AltCheckValue,PREVIOUS_JRE_FILE)
# Set here as shared variables
PREVIOUS_JRE_BUNDLE = $(PREVIOUS_RELEASE_PATH)/$(PREVIOUS_JRE_FILE)
PREVIOUS_JDK_BUNDLE = $(PREVIOUS_RELEASE_PATH)/$(PREVIOUS_JDK_FILE)
# These are the same on all platforms but require the above platform include 1st
# BOOTDIR: Bootstrap JDK, previous released JDK.
......@@ -392,19 +365,70 @@ export BOOTDIR
BOOTDIR:=$(call AltCheckSpaces,BOOTDIR)
BOOTDIR:=$(call AltCheckValue,BOOTDIR)
# PREVIOUS_RELEASE_PATH: path to where previous release bundles are
ifdef ALT_PREVIOUS_RELEASE_PATH
PREVIOUS_RELEASE_PATH :=$(call OptFullPath,$(ALT_PREVIOUS_RELEASE_PATH))
else
PREVIOUS_RELEASE_PATH =$(SLASH_JAVA)/re/jdk/$(PREVIOUS_JDK_VERSION)/archive/fcs/bundles/$(PLATFORM)-$(ARCH)
endif
export PREVIOUS_RELEASE_PATH
PREVIOUS_RELEASE_PATH:=$(call AltCheckSpaces,PREVIOUS_RELEASE_PATH)
PREVIOUS_RELEASE_PATH:=$(call AltCheckValue,PREVIOUS_RELEASE_PATH)
# PREVIOUS_FCS_RE_AREA: re path to where previous release binaries/bundles are
PREVIOUS_FCS_RE_AREA = $(SLASH_JAVA)/re/jdk/$(PREVIOUS_JDK_VERSION)/archive/fcs
# PREVIOUS_RELEASE_IMAGE: Previous install image to compare against
ifdef ALT_PREVIOUS_RELEASE_IMAGE
# Explicit image provided, no bundle access needed
PREVIOUS_RELEASE_IMAGE :=$(call FullPath,$(ALT_PREVIOUS_RELEASE_IMAGE))
else
# PREVIOUS_RELEASE_PATH: path to where previous release bundles are
ifdef ALT_PREVIOUS_RELEASE_PATH
PREVIOUS_RELEASE_PATH :=$(call OptFullPath,$(ALT_PREVIOUS_RELEASE_PATH))
else
PREVIOUS_RELEASE_PATH := \
$(call DirExists,$(PREVIOUS_FCS_RE_AREA)/bundles/$(PLATFORM)-$(ARCH),,)
endif
# Depending on if we have access to these bundles
ifeq ($(PREVIOUS_RELEASE_PATH),)
# Use images in re area or BOOTDIR (which is normally the previous release)
PREVIOUS_RELEASE_IMAGE := \
$(call DirExists,$(PREVIOUS_FCS_RE_AREA)/binaries/$(PLATFORM)-$(ARCH),$(BOOTDIR),)
else
# Get names of and paths to bundles
PREVIOUS_RELEASE_PATH:=$(call AltCheckSpaces,PREVIOUS_RELEASE_PATH)
PREVIOUS_RELEASE_PATH:=$(call AltCheckValue,PREVIOUS_RELEASE_PATH)
export PREVIOUS_RELEASE_PATH
# PREVIOUS_JDK_FILE: filename of install bundle for previous JDK
ifdef ALT_PREVIOUS_JDK_FILE
PREVIOUS_JDK_FILE =$(ALT_PREVIOUS_JDK_FILE)
else
PREVIOUS_JDK_FILE = \
jdk-$(PREVIOUS_JDK_UNDERSCORE_VERSION)-$(PLATFORM)-$(ARCH)$(BUNDLE_FILE_SUFFIX)
endif
export PREVIOUS_JDK_FILE
PREVIOUS_JDK_FILE:=$(call AltCheckSpaces,PREVIOUS_JDK_FILE)
PREVIOUS_JDK_FILE:=$(call AltCheckValue,PREVIOUS_JDK_FILE)
# PREVIOUS_JRE_FILE: filename of install bundle for previous JRE
ifdef ALT_PREVIOUS_JRE_FILE
PREVIOUS_JRE_FILE =$(ALT_PREVIOUS_JRE_FILE)
else
PREVIOUS_JRE_FILE = \
jre-$(PREVIOUS_JDK_UNDERSCORE_VERSION)-$(PLATFORM)-$(ARCH)$(BUNDLE_FILE_SUFFIX)
endif
export PREVIOUS_JRE_FILE
PREVIOUS_JRE_FILE:=$(call AltCheckSpaces,PREVIOUS_JRE_FILE)
PREVIOUS_JRE_FILE:=$(call AltCheckValue,PREVIOUS_JRE_FILE)
# Paths to these bundles
PREVIOUS_JRE_BUNDLE = $(PREVIOUS_RELEASE_PATH)/$(PREVIOUS_JRE_FILE)
PREVIOUS_JDK_BUNDLE = $(PREVIOUS_RELEASE_PATH)/$(PREVIOUS_JDK_FILE)
endif
endif
# Indicate we are using an image comparison
ifneq ($(PREVIOUS_RELEASE_IMAGE),)
PREVIOUS_RELEASE_PATH = USING-PREVIOUS_RELEASE_IMAGE
PREVIOUS_JRE_BUNDLE = USING-PREVIOUS_RELEASE_IMAGE
PREVIOUS_JDK_BUNDLE = USING-PREVIOUS_RELEASE_IMAGE
endif
# CACERTS_FILE: if OPENJDK is false and the internal version of the file
......@@ -516,23 +540,17 @@ JDK_CUPS_HEADERS_PATH=$(JDK_DEVTOOLS_DIR)/share/cups/include
endif
endif
# Utilities ant and findbugs
ifeq ($(ANT_HOME),)
ANT_HOME := $(call DirExists,/usr/share/ant,$(JDK_DEVTOOLS_DIR)/share/ant/latest,)
# Utilities ant
ifeq ($(PLATFORM), windows)
ifeq ($(ANT_HOME),)
ANT_HOME := $(call DirExists,$(JDK_DEVTOOLS_DIR)/share/ant/latest,,)
endif
endif
ifeq ($(ANT_HOME),)
ANT = ant
else
ANT = $(ANT_HOME)/bin/ant
endif
ifeq ($(FINDBUGS_HOME),)
FINDBUGS_HOME := $(call DirExists,/usr/share/findbugs,$(JDK_DEVTOOLS_DIR)/share/findbugs/latest,)
endif
ifeq ($(FINDBUGS_HOME),)
FINDBUGS = findbugs
else
FINDBUGS = $(FINDBUGS_HOME)/bin/findbugs
endif
ifdef ALT_COPYRIGHT_YEAR
COPYRIGHT_YEAR = $(ALT_COPYRIGHT_YEAR)
......
#
# Copyright 2005-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2005-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -79,7 +79,6 @@ ALL_SETTINGS+=$(call addAltSetting,SLASH_JAVA)
ALL_SETTINGS+=$(call addRequiredSetting,VARIANT)
ALL_SETTINGS+=$(call addAltSetting,JDK_DEVTOOLS_DIR)
ALL_SETTINGS+=$(call addOptionalSetting,ANT_HOME)
ALL_SETTINGS+=$(call addOptionalSetting,FINDBUGS_HOME)
ALL_SETTINGS+=$(call addAltSetting,UNIXCOMMAND_PATH)
ALL_SETTINGS+=$(call addAltSetting,COMPILER_PATH)
ALL_SETTINGS+=$(call addAltSetting,DEVTOOLS_PATH)
......@@ -119,7 +118,6 @@ ifeq ($(PLATFORM),windows)
ALL_SETTINGS+=$(call addRequiredVersionSetting,LINK_VER)
endif
ALL_SETTINGS+=$(call addRequiredVersionSetting,ANT_VER)
ALL_SETTINGS+=$(call addRequiredVersionSetting,FINDBUGS_VER)
ALL_SETTINGS+=$(call addRequiredSetting,TEMPDIR)
......
......@@ -107,21 +107,9 @@ UNZIP_VER :=$(call GetVersion,"$(_UNZIP_VER)")
BOOT_VER :=$(call GetVersion,"$(_BOOT_VER)")
REQUIRED_ANT_VER := 1.6.3
ifeq ($(ANT_HOME),)
_ANT_VER:=$(shell JAVACMD="$(BOOTDIR)/bin/java" $(ANT) -version 2>&1 )
else
_ANT_VER:=$(shell JAVACMD="$(BOOTDIR)/bin/java" ANT_HOME="$(ANT_HOME)" $(ANT) -version 2>&1 )
endif
_ANT_VER:=$(shell $(ANT) -version 2>&1 )
ANT_VER:=$(call GetVersion,"$(_ANT_VER)")
REQUIRED_FINDBUGS_VER := 1.2
ifeq ($(FINDBUGS_HOME),)
_FINDBUGS_VER:=$(shell $(FINDBUGS) -javahome "$(BOOTDIR)" -textui -version 2>&1 )
else
_FINDBUGS_VER:=$(shell FINDBUGS_HOME="$(FINDBUGS_HOME)" $(FINDBUGS) -javahome "$(BOOTDIR)" -textui -version 2>&1 )
endif
FINDBUGS_VER:=$(call GetVersion,"$(_FINDBUGS_VER)")
ifdef ALT_BINDIR
ALT_BINDIR_VERSION := $(shell $(ALT_BINDIR)/java$(EXE_SUFFIX) -version 2>&1 | $(NAWK) -F'"' '{ print $$2 }')
ALT_BINDIR_OK := $(shell $(ECHO) $(ALT_BINDIR_VERSION) | $(EGREP) -c '^$(JDK_MAJOR_VERSION).$(JDK_MINOR_VERSION)')
......@@ -182,7 +170,6 @@ include $(JDK_MAKE_SHARED_DIR)/Sanity-Settings.gmk
sane-alsa-versioncheck \
sane-alsa-headers \
sane-ant_version \
sane-findbugs_version \
sane-zip_version \
sane-unzip_version \
sane-msvcrt_path \
......@@ -1216,19 +1203,6 @@ sane-ant_version:
"" >> $(WARNING_FILE) ; \
fi
######################################################
# Check the findbugs version
######################################################
FINDBUGS_CHECK :=$(call CheckVersions,$(FINDBUGS_VER),$(REQUIRED_FINDBUGS_VER))
sane-findbugs_version:
@if [ "$(FINDBUGS_CHECK)" != "same" \
-a "$(FINDBUGS_CHECK)" != "newer" ]; then \
$(ECHO) "WARNING: The version of findbugs being used is older than \n" \
" the required version of '$(REQUIRED_FINDBUGS_VER)'. \n" \
" The version of findbugs found was '$(FINDBUGS_VER)'. \n" \
"" >> $(WARNING_FILE) ; \
fi
######################################################
# Check the zip file version
######################################################
......
......@@ -155,8 +155,10 @@ CORE_PKGS = \
javax.lang.model.type \
javax.lang.model.util \
javax.management \
javax.management.event \
javax.management.loading \
javax.management.monitor \
javax.management.namespace \
javax.management.relation \
javax.management.openmbean \
javax.management.timer \
......
#
# Copyright 1998-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1998-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -33,6 +33,7 @@
BUILDDIR = ../..
LIBRARY = fdlibm
PRODUCT = java
include $(BUILDDIR)/common/Defs.gmk
#
......@@ -40,14 +41,23 @@ include $(BUILDDIR)/common/Defs.gmk
#
FDLIBM_SRC = $(SHARE_SRC)/native/java/lang/fdlibm
# windows compiler flags
# Windows: compiler flags
ifeq ($(PLATFORM),windows)
# Turn all optimizations off
_OPT = $(CC_NO_OPT)
OPTIMIZATION_LEVEL = NONE
OTHER_CFLAGS =
CPPFLAGS_DBG += -DLOGGING
endif
#
# Linux: Disable optimization to get correctly reproducible
# floating-point results.
#
ifeq ($(PLATFORM),linux)
# Turn all optimizations off
OPTIMIZATION_LEVEL = NONE
endif
#
# Include path.
#
......@@ -68,15 +78,6 @@ include FILES_c.gmk
#
include $(BUILDDIR)/common/Library.gmk
#
# Disable optimization to get correctly reproducible
# floating-point results.
#
ifeq ($(PLATFORM),linux)
# Turn all optimizations off
_OPT = $(CC_NO_OPT)
endif
#
# Find fdlibm source files.
#
......
#
# Copyright 1999-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1999-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......
#
# Copyright 1996-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1996-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -450,6 +450,7 @@ JAVA_JAVA_java = \
sun/misc/JavaLangAccess.java \
sun/misc/JavaIOAccess.java \
sun/misc/JavaIODeleteOnExitAccess.java \
sun/misc/JavaIOFileDescriptorAccess.java
sun/misc/JavaIOFileDescriptorAccess.java \
sun/misc/JavaNioAccess.java
FILES_java = $(JAVA_JAVA_java)
......@@ -222,8 +222,6 @@ SUNWprivate_1.1 {
Java_java_lang_UNIXProcess_waitForProcessExit;
Java_java_lang_UNIXProcess_forkAndExec;
Java_java_lang_UNIXProcess_destroyProcess;
Java_java_nio_Bits_copyFromByteArray;
Java_java_nio_Bits_copyToByteArray;
Java_java_nio_Bits_copyFromShortArray;
Java_java_nio_Bits_copyToShortArray;
Java_java_nio_Bits_copyFromIntArray;
......
#
# Copyright 2004-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2004-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......
#
# Copyright 2003-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2003-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -28,14 +28,14 @@ LIBRARY = hprof
PRODUCT = sun
LIBRARY_OUTPUT = hprof_jvmti
# Configure the CFLAGS for this library.
# Use highest optimization
OPTIMIZATION_LEVEL = HIGHEST
# Configure the CFLAGS for this library.
FILES_m = mapfile-vers
include $(BUILDDIR)/common/Defs.gmk
_OPT=$(CC_HIGHEST_OPT)
SRCDIR=$(SHARE_SRC)/demo/jvmti/hprof
PSRCDIR=$(PLATFORM_SRC)/demo/jvmti/hprof
......
......@@ -113,7 +113,11 @@ ifeq ($(PLATFORM), windows)
JAVALIB =
OTHER_LCF = -export:JLI_Launch \
-export:JLI_ManifestIterate \
-export:JLI_SetTraceLauncher
-export:JLI_SetTraceLauncher \
-export:JLI_ReportErrorMessage \
-export:JLI_ReportErrorMessageSys \
-export:JLI_ReportMessage \
-export:JLI_ReportExceptionDescription
endif
......
#
# Copyright 2005-2006 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2005-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -30,6 +30,10 @@ SUNWprivate_1.1 {
JLI_Launch;
JLI_ManifestIterate;
JLI_SetTraceLauncher;
JLI_ReportErrorMessage;
JLI_ReportErrorMessageSys;
JLI_ReportMessage;
JLI_ReportExceptionDescription;
local:
*;
};
#
# Copyright 2003-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2003-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -93,7 +93,8 @@ endif
include $(BUILDDIR)/common/Library.gmk
$(AGENTJAR): $(LIBDIR) $(TEMPDIR)/manifest
$(BOOT_JAR_CMD) -cfm $(AGENTJAR) $(TEMPDIR)/manifest
$(BOOT_JAR_CMD) -cfm $(AGENTJAR) $(TEMPDIR)/manifest $(BOOT_JAR_JFLAGS)
@$(java-vm-cleanup)
$(TEMPDIR)/manifest: $(MANIFEST)
$(install-file)
......
#
# Copyright 1995-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1995-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......
#
# Copyright 1997-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1997-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -57,7 +57,7 @@ SUNWprivate_1.1 {
Java_java_net_Inet6AddressImpl_isReachable0;
Java_java_net_NetworkInterface_init;
Java_java_net_NetworkInterface_getByName0;
Java_java_net_NetworkInterface_getByIndex;
Java_java_net_NetworkInterface_getByIndex0;
Java_java_net_NetworkInterface_getByInetAddress0;
Java_java_net_NetworkInterface_getAll;
Java_java_net_NetworkInterface_isUp0;
......
#
# Copyright 2000-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2000-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -26,6 +26,7 @@
FILES_src = \
java/nio/Bits.java \
java/nio/Buffer.java \
java/nio/BufferPoolMXBean.java \
java/nio/ByteOrder.java \
java/nio/MappedByteBuffer.java \
java/nio/StringCharBuffer.java \
......@@ -38,6 +39,9 @@ FILES_src = \
java/nio/channels/FileLock.java \
java/nio/channels/GatheringByteChannel.java \
java/nio/channels/InterruptibleChannel.java \
java/nio/channels/MembershipKey.java \
java/nio/channels/MulticastChannel.java \
java/nio/channels/NetworkChannel.java \
java/nio/channels/ReadableByteChannel.java \
java/nio/channels/ScatteringByteChannel.java \
java/nio/channels/SelectableChannel.java \
......@@ -72,6 +76,7 @@ FILES_src = \
sun/nio/ch/DatagramSocketAdaptor.java \
sun/nio/ch/DefaultSelectorProvider.java \
sun/nio/ch/DirectBuffer.java \
sun/nio/ch/ExtendedSocketOption.java \
sun/nio/ch/FileChannelImpl.java \
sun/nio/ch/FileDispatcher.java \
sun/nio/ch/FileKey.java \
......@@ -79,12 +84,14 @@ FILES_src = \
sun/nio/ch/IOUtil.java \
sun/nio/ch/IOStatus.java \
sun/nio/ch/IOVecWrapper.java \
sun/nio/ch/MembershipKeyImpl.java \
sun/nio/ch/MembershipRegistry.java \
sun/nio/ch/NativeDispatcher.java \
sun/nio/ch/NativeObject.java \
sun/nio/ch/NativeThread.java \
sun/nio/ch/NativeThreadSet.java \
sun/nio/ch/Net.java \
sun/nio/ch/OptionAdaptor.java \
sun/nio/ch/OptionKey.java \
sun/nio/ch/PipeImpl.java \
sun/nio/ch/PollArrayWrapper.java \
sun/nio/ch/Reflect.java \
......@@ -98,8 +105,7 @@ FILES_src = \
sun/nio/ch/SocketAdaptor.java \
sun/nio/ch/SocketChannelImpl.java \
sun/nio/ch/SocketDispatcher.java \
sun/nio/ch/SocketOpts.java \
sun/nio/ch/SocketOptsImpl.java \
sun/nio/ch/SocketOptionRegistry.java \
sun/nio/ch/SourceChannelImpl.java \
sun/nio/ch/Util.java \
\
......@@ -239,6 +245,7 @@ FILES_gen_ex = \
java/nio/InvalidMarkException.java \
java/nio/ReadOnlyBufferException.java \
\
java/nio/channels/AlreadyBoundException.java \
java/nio/channels/AlreadyConnectedException.java \
java/nio/channels/AsynchronousCloseException.java \
java/nio/channels/ClosedByInterruptException.java \
......@@ -257,14 +264,15 @@ FILES_gen_ex = \
java/nio/channels/UnresolvedAddressException.java \
java/nio/channels/UnsupportedAddressTypeException.java \
\
sun/nio/ch/AlreadyBoundException.java \
\
java/nio/charset/CharacterCodingException.java \
java/nio/charset/IllegalCharsetNameException.java \
java/nio/charset/UnsupportedCharsetException.java
FILES_gen_csp = sun/nio/cs/StandardCharsets.java
FILES_gen = $(FILES_gen_coder) $(FILES_gen_buffer) $(FILES_gen_ex) $(FILES_gen_csp)
FILES_gen_sor = sun/nio/ch/SocketOptionRegistry.java
FILES_gen = $(FILES_gen_coder) $(FILES_gen_buffer) $(FILES_gen_ex) \
$(FILES_gen_csp) $(FILES_gen_sor)
FILES_java = $(FILES_src) $(FILES_gen)
......@@ -56,18 +56,18 @@ FILES_java += \
sun/nio/ch/DevPollSelectorProvider.java \
sun/nio/ch/InheritedChannel.java \
sun/nio/ch/PollSelectorProvider.java \
sun/nio/ch/PollSelectorImpl.java
sun/nio/ch/PollSelectorImpl.java
FILES_c += \
DevPollArrayWrapper.c \
InheritedChannel.c \
PollArrayWrapper.c \
NativeThread.c
NativeThread.c \
PollArrayWrapper.c
FILES_export += \
sun/nio/ch/DevPollArrayWrapper.java \
sun/nio/ch/InheritedChannel.java \
sun/nio/ch/NativeThread.java
sun/nio/ch/NativeThread.java
endif # PLATFORM = solaris
ifeq ($(PLATFORM), windows)
......@@ -94,14 +94,14 @@ FILES_java += \
FILES_c += \
EPollArrayWrapper.c \
PollArrayWrapper.c \
InheritedChannel.c \
NativeThread.c
NativeThread.c \
PollArrayWrapper.c
FILES_export += \
sun/nio/ch/EPollArrayWrapper.java \
sun/nio/ch/InheritedChannel.java \
sun/nio/ch/NativeThread.java
sun/nio/ch/NativeThread.java
endif # PLATFORM = linux
# Find platform-specific C source files
......@@ -618,12 +618,6 @@ $(BUF_GEN)/%Exception.java: genExceptions.sh $(BUF_SRC)/exceptions
@$(RM) $@.temp
$(GEN_EX_CMD) $(BUF_SRC)/exceptions $(BUF_GEN)
$(SCH_GEN)/%Exception.java: genExceptions.sh $(SCH_SRC)/exceptions
$(prep-target)
@$(RM) $@.temp
$(GEN_EX_CMD) $(SCH_SRC)/exceptions $(SCH_GEN)
#
# Generated charset-provider classes
#
......@@ -638,4 +632,29 @@ $(SCS_GEN)/StandardCharsets.java: genCharsetProvider.sh \
HASHER="$(BOOT_JAVA_CMD) -jar $(HASHER_JARFILE)" \
$(SH) -e genCharsetProvider.sh $(SCS_SRC)/standard-charsets $(SCS_GEN)
#
# Generated channel implementation classes.
# C source is compiled in TEMPDIR to avoid turds left by Windows compilers.
#
GENSOR_SRC = $(SHARE_SRC)/native/sun/nio/ch/genSocketOptionRegistry.c
GENSOR_EXE = $(TEMPDIR)/genSocketOptionRegistry$(EXE_SUFFIX)
SOR_COPYRIGHT_YEARS = $(shell $(CAT) $(GENSOR_SRC) | \
$(NAWK) '/^.*Copyright.*Sun/ { print $$3 }')
$(TEMPDIR)/$(GENSOR_SRC) : $(GENSOR_SRC)
$(install-file)
$(GENSOR_EXE) : $(TEMPDIR)/$(GENSOR_SRC)
$(prep-target)
($(CD) $(TEMPDIR); $(CC) $(CPPFLAGS) $(LDDFLAGS) \
-o genSocketOptionRegistry$(EXE_SUFFIX) $(GENSOR_SRC))
$(SCH_GEN)/SocketOptionRegistry.java: $(GENSOR_EXE)
$(prep-target)
NAWK="$(NAWK)" SH="$(SH)" $(SH) -e addNotices.sh $(SOR_COPYRIGHT_YEARS) > $@
$(GENSOR_EXE) >> $@
.PHONY: sources
#! /bin/sh
#
# Copyright 2000-2001 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2000-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......
此差异已折叠。
此差异已折叠。
#
# Copyright 2004-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2004-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......
#
# Copyright 1999-2005 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1999-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......@@ -52,12 +52,6 @@ FILES_c = \
check_code.c \
check_format.c
#
# libverify.so needs these 2 header files (opcodes.h opcodes.length)
# from the VM.
#
CPPFLAGS += -I$(SHARE_SRC)/javavm/include
#
# Targets.
#
......
#
# Copyright 1996-2006 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1996-2008 Sun Microsystems, Inc. All Rights Reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
......
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册