src/demo/share/java2d/J2DBench/Makefile
changeset 47216 71c04702a3d5
parent 26353 b5e3b7fbf56d
equal deleted inserted replaced
47215:4ebc2e2fb97c 47216:71c04702a3d5
       
     1 #
       
     2 # Copyright (c) 2002, 2007, Oracle and/or its affiliates. All rights reserved.
       
     3 #
       
     4 # Redistribution and use in source and binary forms, with or without
       
     5 # modification, are permitted provided that the following conditions
       
     6 # are met:
       
     7 #
       
     8 #   - Redistributions of source code must retain the above copyright
       
     9 #     notice, this list of conditions and the following disclaimer.
       
    10 #
       
    11 #   - Redistributions in binary form must reproduce the above copyright
       
    12 #     notice, this list of conditions and the following disclaimer in the
       
    13 #     documentation and/or other materials provided with the distribution.
       
    14 #
       
    15 #   - Neither the name of Oracle nor the names of its
       
    16 #     contributors may be used to endorse or promote products derived
       
    17 #     from this software without specific prior written permission.
       
    18 #
       
    19 # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
       
    20 # IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
       
    21 # THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
       
    22 # PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR
       
    23 # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
       
    24 # EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
       
    25 # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
       
    26 # PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
       
    27 # LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
       
    28 # NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
       
    29 # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
       
    30 #
       
    31 
       
    32 SOURCEPATH=src
       
    33 CLASSES=build
       
    34 DIST=dist
       
    35 RESOURCES=resources
       
    36 
       
    37 J2DBENCH_CLASSES = \
       
    38 	$(CLASSES)/j2dbench/J2DBench.class \
       
    39 	$(CLASSES)/j2dbench/Destinations.class \
       
    40 	$(CLASSES)/j2dbench/Group.class \
       
    41 	$(CLASSES)/j2dbench/Result.class \
       
    42 	$(CLASSES)/j2dbench/Modifier.class \
       
    43 	$(CLASSES)/j2dbench/Node.class \
       
    44 	$(CLASSES)/j2dbench/Option.class \
       
    45 	$(CLASSES)/j2dbench/ResultSet.class \
       
    46 	$(CLASSES)/j2dbench/TestEnvironment.class \
       
    47 	$(CLASSES)/j2dbench/Test.class \
       
    48 	$(CLASSES)/j2dbench/ui/EnableButton.class \
       
    49 	$(CLASSES)/j2dbench/ui/CompactLayout.class \
       
    50 	$(CLASSES)/j2dbench/tests/ImageTests.class \
       
    51 	$(CLASSES)/j2dbench/tests/RenderTests.class \
       
    52 	$(CLASSES)/j2dbench/tests/PixelTests.class \
       
    53 	$(CLASSES)/j2dbench/tests/MiscTests.class \
       
    54 	$(CLASSES)/j2dbench/tests/iio/IIOTests.class \
       
    55 	$(CLASSES)/j2dbench/tests/iio/InputTests.class \
       
    56 	$(CLASSES)/j2dbench/tests/iio/InputImageTests.class \
       
    57 	$(CLASSES)/j2dbench/tests/iio/InputStreamTests.class \
       
    58 	$(CLASSES)/j2dbench/tests/iio/OutputTests.class \
       
    59 	$(CLASSES)/j2dbench/tests/iio/OutputImageTests.class \
       
    60 	$(CLASSES)/j2dbench/tests/iio/OutputStreamTests.class \
       
    61 	$(CLASSES)/j2dbench/tests/text/TextConstructionTests.class \
       
    62 	$(CLASSES)/j2dbench/tests/text/TextMeasureTests.class \
       
    63 	$(CLASSES)/j2dbench/tests/text/TextRenderTests.class \
       
    64 	$(CLASSES)/j2dbench/tests/text/TextTests.class \
       
    65 	$(CLASSES)/j2dbench/tests/GraphicsTests.class
       
    66 
       
    67 J2DANALYZER_CLASSES = \
       
    68 	$(CLASSES)/j2dbench/report/IIOComparator.class \
       
    69 	$(CLASSES)/j2dbench/report/HTMLSeriesReporter.class \
       
    70 	$(CLASSES)/j2dbench/report/J2DAnalyzer.class \
       
    71 	$(CLASSES)/j2dbench/report/XMLHTMLReporter.class
       
    72 
       
    73 J2DBENCH_RESOURCES = \
       
    74 	$(CLASSES)/j2dbench/tests/iio/images \
       
    75 	$(CLASSES)/j2dbench/tests/cmm/images \
       
    76 	$(CLASSES)/j2dbench/tests/text/textdata
       
    77 
       
    78 SCM_DIRs = .hg .svn CVS RCS SCCS Codemgr_wsdata deleted_files
       
    79 
       
    80 all: mkdirs J2DBench.jar J2DAnalyzer.jar
       
    81 
       
    82 run: mkdirs J2DBench.jar
       
    83 	java -jar J2DBench.jar
       
    84 
       
    85 analyze: mkdirs J2DAnalyzer.jar
       
    86 	java -jar J2DAnalyzer.jar
       
    87 
       
    88 J2DBench.jar: \
       
    89 	$(J2DBENCH_CLASSES) $(J2DBENCH_RESOURCES) \
       
    90 	$(CLASSES)/j2dbench.manifest
       
    91 	jar cvmf $(CLASSES)/j2dbench.manifest $(DIST)/J2DBench.jar -C $(CLASSES) j2dbench
       
    92 
       
    93 J2DAnalyzer.jar: $(J2DANALYZER_CLASSES) $(CLASSES)/j2danalyzer.manifest
       
    94 	jar cvmf $(CLASSES)/j2danalyzer.manifest \
       
    95 		$(DIST)/J2DAnalyzer.jar -C $(CLASSES) j2dbench/report
       
    96 
       
    97 $(CLASSES)/j2dbench/tests/iio/images: $(RESOURCES)/images
       
    98 	cp -r $< $@
       
    99 	cd $@ && rm -rf $(SCM_DIRs)
       
   100 
       
   101 $(CLASSES)/j2dbench/tests/text/textdata: $(RESOURCES)/textdata
       
   102 	cp -r $< $@
       
   103 	cd $@ && rm -rf $(SCM_DIRs)
       
   104 
       
   105 $(CLASSES)/j2dbench/tests/cmm/images: $(RESOURCES)/cmm_images
       
   106 	cp -r $< $@
       
   107 	cd $@ && rm -rf $(SCM_DIRs)
       
   108 
       
   109 $(CLASSES)/j2dbench.manifest:
       
   110 	echo "Main-Class: j2dbench.J2DBench" > $@
       
   111 
       
   112 $(CLASSES)/j2danalyzer.manifest:
       
   113 	echo "Main-Class: j2dbench.report.J2DAnalyzer" > $@
       
   114 
       
   115 $(DIST):
       
   116 	mkdir $(DIST)
       
   117 $(CLASSES):
       
   118 	mkdir $(CLASSES)
       
   119 
       
   120 mkdirs: $(DIST) $(CLASSES)
       
   121 
       
   122 $(CLASSES)/j2dbench/%.class: $(SOURCEPATH)/j2dbench/%.java
       
   123 	javac -g:none -source 1.6 -target 1.6 -d $(CLASSES) -sourcepath $(SOURCEPATH) $<
       
   124 
       
   125 clean:
       
   126 	rm -rf $(CLASSES)
       
   127 	rm -rf $(DIST)