18 # |
18 # |
19 # CDDL HEADER END |
19 # CDDL HEADER END |
20 # |
20 # |
21 |
21 |
22 # |
22 # |
23 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. |
23 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. |
24 # |
24 # |
|
25 |
|
26 # for the tests |
|
27 COMPILER=gcc |
25 |
28 |
26 include ../../make-rules/shared-macros.mk |
29 include ../../make-rules/shared-macros.mk |
27 |
30 |
28 COMPONENT_NAME= bison |
31 COMPONENT_NAME= bison |
29 COMPONENT_VERSION= 2.3 |
32 COMPONENT_VERSION= 3.0.4 |
30 COMPONENT_PROJECT_URL= http://www.gnu.org/software/bison/ |
33 COMPONENT_PROJECT_URL= http://www.gnu.org/software/bison/ |
31 COMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION) |
34 COMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION) |
32 COMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz |
35 COMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.xz |
33 COMPONENT_ARCHIVE_HASH= \ |
36 COMPONENT_ARCHIVE_HASH= \ |
34 sha256:52f78aa4761a74ceb7fdf770f3554dd84308c3b93c4255e3a5c17558ecda293e |
37 sha256:a72428c7917bdf9fa93cb8181c971b6e22834125848cf1d03ce10b1bb0716fe1 |
35 COMPONENT_ARCHIVE_URL= http://ftp.gnu.org/gnu/bison/$(COMPONENT_ARCHIVE) |
38 COMPONENT_ARCHIVE_URL= http://ftp.gnu.org/pub/gnu/bison/$(COMPONENT_ARCHIVE) |
36 COMPONENT_BUGDB= utility/bison |
39 COMPONENT_BUGDB= utility/bison |
37 |
40 |
38 TPNO= 6254 |
41 TPNO= 24440 |
39 |
42 |
40 include $(WS_MAKE_RULES)/prep.mk |
43 include $(WS_MAKE_RULES)/prep.mk |
41 include $(WS_MAKE_RULES)/configure.mk |
44 include $(WS_MAKE_RULES)/configure.mk |
42 include $(WS_MAKE_RULES)/ips.mk |
45 include $(WS_MAKE_RULES)/ips.mk |
43 |
46 |
44 CONFIGURE_LIBDIR.32 = $(GNULIB) |
47 CONFIGURE_LIBDIR.32 = $(GNULIB) |
45 CONFIGURE_LIBDIR.64 = $(GNULIB)/$(MACH64) |
48 CONFIGURE_LIBDIR.64 = $(GNULIB)/$(MACH64) |
46 |
49 |
|
50 COMPONENT_PRE_CONFIGURE_ACTION = \ |
|
51 ($(CLONEY) $(SOURCE_DIR) $(@D)) |
|
52 |
47 CONFIGURE_OPTIONS += --infodir=$(CONFIGURE_INFODIR) |
53 CONFIGURE_OPTIONS += --infodir=$(CONFIGURE_INFODIR) |
48 CONFIGURE_OPTIONS += CFLAGS="$(CFLAGS)" |
54 CONFIGURE_OPTIONS += CFLAGS="$(CFLAGS)" |
|
55 CONFIGURE_OPTIONS += M4="/usr/gnu/bin/m4" |
|
56 CONFIGURE_OPTIONS += --disable-silent-rules |
|
57 |
|
58 # the shared library we create needs to be built pic |
|
59 COMPONENT_BUILD_ARGS += CC_PIC="$(CC_PIC)" |
|
60 |
|
61 # this is cheesy but the tests don't seem to |
|
62 # get compiled with the CFLAGS we built bison |
|
63 # with, so they are 32-bit otherwise. |
|
64 CONFIGURE_OPTIONS += WARN_CXXFLAGS_TEST="$(CFLAGS)" |
49 |
65 |
50 COMPONENT_TEST_MASTER = $(COMPONENT_TEST_RESULTS_DIR)/results-all.master |
66 COMPONENT_TEST_MASTER = $(COMPONENT_TEST_RESULTS_DIR)/results-all.master |
51 |
67 |
52 # the test suite actually generates a script |
68 # the test suite actually generates a script |
53 # that runs the just-built bison against the |
69 # that runs the just-built bison against the |
55 # one, we can just replace that script with |
71 # one, we can just replace that script with |
56 # a simpler one |
72 # a simpler one |
57 COMPONENT_PRE_SYSTEM_TEST_ACTION= \ |
73 COMPONENT_PRE_SYSTEM_TEST_ACTION= \ |
58 (cd $(@D)/tests; mv bison bison.orig; \ |
74 (cd $(@D)/tests; mv bison bison.orig; \ |
59 echo "\#!/bin/bash" > bison; \ |
75 echo "\#!/bin/bash" > bison; \ |
|
76 echo "IFS=" >> bison; \ |
60 echo "exec /usr/bin/bison \$$@" >> bison; \ |
77 echo "exec /usr/bin/bison \$$@" >> bison; \ |
61 chmod +x bison; \ |
78 chmod +x bison; \ |
62 ) |
79 ) |
63 |
80 |
64 COMPONENT_POST_SYSTEM_TEST_ACTION= \ |
81 COMPONENT_POST_SYSTEM_TEST_ACTION= \ |
65 (cd $(@D)/tests; rm -f bison; mv bison.orig bison) |
82 (cd $(@D)/tests; rm -f bison; mv bison.orig bison) |
66 |
83 |
67 # Strip compilation lines from test output |
84 # Strip compilation lines from test output |
|
85 # and strange backslash lines. and random output, |
|
86 # including rm complaints over nfs |
68 COMPONENT_TEST_TRANSFORMS += \ |
87 COMPONENT_TEST_TRANSFORMS += \ |
69 '-e "s|^.*$(CC).*$$|XXX_CC_XXX|g" ' \ |
88 '-e "s|^.*$(CC).*$$|XXX_CC_XXX|g" ' \ |
70 '-e "s|^.*$(CXX).*$$|XXX_CC_XXX|g" ' \ |
89 '-e "s|^.*$(CXX).*$$|XXX_CC_XXX|g" ' \ |
71 '-e "s|^.*source=.*libtool=no.*$$|XXX_CC_XXX|g" ' \ |
90 '-e "s|^.*source=.*libtool=no.*$$|XXX_CC_XXX|g" ' \ |
72 '-e "s|^.*DEPDIR=.deps.*$$|XXX_CC_XXX|g" ' \ |
91 '-e "s|^.*DEPDIR=.deps.*$$|XXX_CC_XXX|g" ' \ |
73 '-e "s|^config.status: .*$$|XXX_CC_XXX|g" ' \ |
92 '-e "s|^config.status: .*$$|XXX_CC_XXX|g" ' \ |
74 '-e "s|^make.*: Leaving directory.*$$|XXX_CC_XXX|g" ' \ |
93 '-e "s|^make.*: Leaving directory.*$$|XXX_CC_XXX|g" ' \ |
75 '-e "s|^make.*: Entering directory.*$$|XXX_CC_XXX|g" ' \ |
94 '-e "s|^make.*: Entering directory.*$$|XXX_CC_XXX|g" ' \ |
|
95 '-e "s|^make.*: Nothing to be done for.*$$|XXX_CC_XXX|g" ' \ |
|
96 '-e "s|^make.*: .*is up to date.*$$|XXX_CC_XXX|g" ' \ |
|
97 '-e "s|^mv -f.*$$|XXX_CC_XXX|g" ' \ |
|
98 '-e "s|^.$$|XXX_CC_XXX|g" ' \ |
|
99 '-e "s|^updating examples.*$$|XXX_CC_XXX|g" ' \ |
|
100 '-e "s|.*build-aux/ylwrap.*$$|XXX_CC_XXX|g" ' \ |
|
101 '-e "s|.*examples/calc++/calc++-parser.stamp.*$$|XXX_CC_XXX|g" ' \ |
|
102 '-e "s|.*tests/bison -o y.tab.c.*$$|XXX_CC_XXX|g" ' \ |
|
103 '-e "s|^rm:.*directory renamed.*$$|XXX_CC_XXX|g" ' \ |
76 '-e "/^XXX_CC_XXX$$/d" ' |
104 '-e "/^XXX_CC_XXX$$/d" ' |
77 |
105 |
78 # Enable ASLR for this component |
106 # Enable ASLR for this component |
79 ASLR_MODE = $(ASLR_ENABLE) |
107 ASLR_MODE = $(ASLR_ENABLE) |
80 |
108 |