perl/Term-Table: update to 0.023 for Perl 5.40
[oi-userland.git] / components / developer / ant / Makefile
blobe90d53b0930afc5241347c415716943159b4715c
2 # CDDL HEADER START
4 # The contents of this file are subject to the terms of the
5 # Common Development and Distribution License (the "License").
6 # You may not use this file except in compliance with the License.
8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 # or http://www.opensolaris.org/os/licensing.
10 # See the License for the specific language governing permissions
11 # and limitations under the License.
13 # When distributing Covered Code, include this CDDL HEADER in each
14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 # If applicable, add the following below this CDDL HEADER, with the
16 # fields enclosed by brackets "[]" replaced with your own identifying
17 # information: Portions Copyright [yyyy] [name of copyright owner]
19 # CDDL HEADER END
23 # Copyright (c), 2011, 2012, Oracle and/or its affiliates. All rights reserved.
24 # Copyright 2017, Wiselabs Software Ltda - http://www.wiselabs.com.br. All rights reserved.
25 # Copyright 2023 Niklas Poslovski
28 BUILD_STYLE = justmake
29 include ../../../make-rules/shared-macros.mk
31 COMPONENT_NAME= ant
32 COMPONENT_VERSION= 1.10.14
33 COMPONENT_SUMMARY= Apache Ant is a Java-based build tool
34 COMPONENT_PROJECT_URL= https://ant.apache.org/
35 COMPONENT_SRC_NAME= apache-ant
36 COMPONENT_SRC= $(COMPONENT_SRC_NAME)-$(COMPONENT_VERSION)
37 COMPONENT_ARCHIVE= $(COMPONENT_SRC)-src.tar.bz2
38 COMPONENT_ARCHIVE_HASH= sha256:c451b8abca000892ef82f9e23ab26b02369973f5ca76fdf2b8d8fa258debffef
39 COMPONENT_ARCHIVE_URL= https://archive.apache.org/dist/ant/source/$(COMPONENT_ARCHIVE)
40 COMPONENT_FMRI= developer/build/ant
41 COMPONENT_CLASSIFICATION= Development/Distribution Tools
42 COMPONENT_LICENSE= Apache v2.0
43 COMPONENT_LICENSE_FILE= LICENSE
45 include $(WS_TOP)/make-rules/common.mk
47 $(BUILD_$(MK_BITS)): GMAKE=./build.sh
48 $(INSTALL_$(MK_BITS)): GMAKE=./build.sh
49 $(TEST_$(MK_BITS)): GMAKE=./build.sh
51 ANT_ENV += JAVA_HOME=$(JAVA_HOME)
53 ANT_DIST_DIRS += -Ddist.dir=$(PROTO_DIR)
54 ANT_DIST_DIRS += -Ddist.bin=$(PROTO_DIR)/usr/bin
55 ANT_DIST_DIRS += -Ddist.etc=$(PROTO_DIR)/usr/share/lib/ant
56 ANT_DIST_DIRS += -Ddist.docs=$(PROTO_DIR)/usr/share/doc/ant
57 ANT_DIST_DIRS += -Ddist.manual=$(PROTO_DIR)/usr/share/doc/ant/manual
58 ANT_DIST_DIRS += -Ddist.javadocs=$(PROTO_DIR)/usr/share/doc/ant/manual/api
59 ANT_DIST_DIRS += -Ddist.lib=$(PROTO_DIR)/usr/share/lib/ant
61 OPTIONAL_LIBS += /usr/share/lib/java/junit.jar
62 OPTIONAL_LIBS += /usr/share/lib/java/bsf.jar
63 OPTIONAL_LIBS += /usr/share/antlr-2.7.7/antlr.jar
65 COMPONENT_PRE_BUILD_ACTION = $(CP) $(OPTIONAL_LIBS) $(@D)/lib/optional
67 # pkgdepend doesn't like the first line of a Python script to be:
68 # '#!/usr/bin/python' so turn it into '#!/usr/bin/python$(PYTHON_VERSION)'
70 COMPONENT_POST_INSTALL_ACTION += \
71 $(GSED) -i -e 's?\/usr\/bin\/python?\/usr\/bin\/python$(PYTHON_VERSION)?' \
72 $(PROTOUSRBINDIR)/runant.py;
74 COMPONENT_BUILD_ARGS =
75 COMPONENT_BUILD_TARGETS = build
76 COMPONENT_BUILD_ENV += $(ANT_ENV)
78 COMPONENT_INSTALL_ARGS = $(ANT_DIST_DIRS)
79 COMPONENT_INSTALL_TARGETS = dist
80 COMPONENT_INSTALL_ENV += $(ANT_ENV)
82 COMPONENT_TEST_TARGETS = test
83 COMPONENT_TEST_ENV += $(ANT_ENV)
84 COMPONENT_TEST_TRANSFORMS += \
85 '-n ' \
86 '-e "s/[0-9]*\.*[0-9]* sec//" ' \
87 '-e "s/[0-9]*ms//" ' \
88 '-e "s/[0-9]* minutes//" ' \
89 '-e "s/[0-9]* seconds//" ' \
90 '-e "s/Time elapsed: [0-9]*,/Time elapsed: /" ' \
91 '-e "/BUILD/p" ' \
92 '-e "/Testsuite/p" ' \
93 '-e "/Testcase/p" ' \
94 '-e "/Tests run/p" '
96 # Build dependencies
97 REQUIRED_PACKAGES += developer/java/openjdk8
98 REQUIRED_PACKAGES += developer/parser/antlr-2
99 REQUIRED_PACKAGES += runtime/java/openjdk8
100 REQUIRED_PACKAGES += library/java/commons-bsf
102 # Auto-generated dependencies
103 PYTHON_REQUIRED_PACKAGES += runtime/python
104 REQUIRED_PACKAGES += runtime/perl
105 REQUIRED_PACKAGES += shell/ksh93