20 # |
20 # |
21 |
21 |
22 # |
22 # |
23 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. |
23 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. |
24 # |
24 # |
25 |
25 BUILD_BITS= 64 |
26 include ../../make-rules/shared-macros.mk |
26 include ../../make-rules/shared-macros.mk |
27 include $(WS_MAKE_RULES)/shared-targets.mk |
27 include $(WS_MAKE_RULES)/shared-targets.mk |
28 |
28 |
29 COMPONENT_NAME= zsh |
29 COMPONENT_NAME= zsh |
30 COMPONENT_VERSION= 5.2 |
30 COMPONENT_VERSION= 5.2 |
31 COMPONENT_PROJECT_URL= http://www.zsh.org/ |
31 COMPONENT_PROJECT_URL= http://www.zsh.org/ |
32 COMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION) |
|
33 COMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.xz |
32 COMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.xz |
34 COMPONENT_ARCHIVE_HASH= \ |
33 COMPONENT_ARCHIVE_HASH= \ |
35 sha256:f17916320ffaa844bbd7ce48ceeb5945fc5f3eff64b149b4229bbfbdf3795a9d |
34 sha256:f17916320ffaa844bbd7ce48ceeb5945fc5f3eff64b149b4229bbfbdf3795a9d |
36 COMPONENT_ARCHIVE_URL= http://downloads.sourceforge.net/project/zsh/zsh/$(COMPONENT_VERSION)/$(COMPONENT_ARCHIVE) |
35 COMPONENT_ARCHIVE_URL= http://downloads.sourceforge.net/project/zsh/zsh/$(COMPONENT_VERSION)/$(COMPONENT_ARCHIVE) |
37 COMPONENT_BUGDB= utility/zsh |
|
38 |
36 |
39 TPNO= 26447 |
37 TPNO= 26447 |
40 |
38 |
41 include $(WS_MAKE_RULES)/prep.mk |
39 BUILD_TARGET= |
42 include $(WS_MAKE_RULES)/configure.mk |
40 INSTALL_TARGET= |
43 include $(WS_MAKE_RULES)/ips.mk |
41 include $(WS_MAKE_RULES)/common.mk |
|
42 |
|
43 CONFIGURE_LIBDIR.64= $(CONFIGURE_LIBDIR.32) |
44 |
44 |
45 CONFIGURE_OPTIONS += -n |
45 CONFIGURE_OPTIONS += -n |
46 CONFIGURE_OPTIONS += --bindir=/usr/bin |
|
47 CONFIGURE_OPTIONS += --libdir=/usr/lib |
|
48 CONFIGURE_OPTIONS += --enable-cppflags="$(CPP_LARGEFILES)" |
46 CONFIGURE_OPTIONS += --enable-cppflags="$(CPP_LARGEFILES)" |
49 CONFIGURE_OPTIONS += --enable-dynamic |
47 CONFIGURE_OPTIONS += --enable-dynamic |
50 CONFIGURE_OPTIONS += --enable-etcdir=/etc |
48 CONFIGURE_OPTIONS += --enable-etcdir=$(ETCDIR) |
51 CONFIGURE_OPTIONS += --enable-function-subdirs |
49 CONFIGURE_OPTIONS += --enable-function-subdirs |
52 # Zsh uses the compiler to link, so we need to pass CC_BITS, not LD_BITS. |
50 # Zsh uses the compiler to link, so we need to pass CC_BITS, not LD_BITS. |
53 CONFIGURE_OPTIONS += --enable-ldflags="$(CC_BITS) -zignore" |
51 CONFIGURE_OPTIONS += --enable-ldflags="$(CC_BITS) -zignore" |
|
52 ifeq ($(OS_VERSION),5.11) |
54 CONFIGURE_OPTIONS += --enable-libs="-lnsl" |
53 CONFIGURE_OPTIONS += --enable-libs="-lnsl" |
|
54 endif |
55 CONFIGURE_OPTIONS += --enable-maildir-support |
55 CONFIGURE_OPTIONS += --enable-maildir-support |
56 CONFIGURE_OPTIONS += --enable-multibyte |
56 CONFIGURE_OPTIONS += --enable-multibyte |
57 CONFIGURE_OPTIONS += --enable-pcre |
57 CONFIGURE_OPTIONS += --enable-pcre |
58 CONFIGURE_OPTIONS += --with-tcsetpgrp |
58 CONFIGURE_OPTIONS += --with-tcsetpgrp |
59 CONFIGURE_OPTIONS += --disable-gdbm |
59 CONFIGURE_OPTIONS += --disable-gdbm |
60 CONFIGURE_OPTIONS += CFLAGS="$(CFLAGS)" |
|
61 |
60 |
62 # pcre-config --libs unnecessarily emits "-R/usr/lib"; we remove it so that it |
61 # pcre-config --libs unnecessarily emits "-R$(USRLIBDIR64)"; we remove it so that it |
63 # doesn't end up in the binaries. |
62 # doesn't end up in the binaries. |
64 COMPONENT_POST_CONFIGURE_ACTION = \ |
63 COMPONENT_POST_CONFIGURE_ACTION = \ |
65 (cd $(@D); \ |
64 (cd $(@D); \ |
66 sed -e 's,-R/usr/lib,,' \ |
65 sed -e "s,-R$(USRLIBDIR64),," \ |
67 config.status > config.status.new; \ |
66 config.status > config.status.new; \ |
68 mv config.status.new config.status; \ |
67 mv config.status.new config.status; \ |
69 chmod 755 config.status; \ |
68 chmod 755 config.status; \ |
70 ./config.status) |
69 ./config.status) |
71 |
70 |
96 license: $(COMPONENT_SRC)/LICENCE |
95 license: $(COMPONENT_SRC)/LICENCE |
97 tail +13 $< > $@ |
96 tail +13 $< > $@ |
98 |
97 |
99 CLEAN_PATHS += license |
98 CLEAN_PATHS += license |
100 |
99 |
101 ASLR_MODE = $(ASLR_ENABLE) |
|
102 |
|
103 # common targets |
100 # common targets |
104 configure: $(CONFIGURE_64) |
|
105 |
|
106 build: $(BUILD_64) $(COMPOVERRIDES:%=$(COMPONENT_SRC)/%) |
101 build: $(BUILD_64) $(COMPOVERRIDES:%=$(COMPONENT_SRC)/%) |
107 |
102 |
108 install: build $(INSTALL_64) $(PROTOETCDIR)/zprofile $(PROTOETCDIR)/zshrc license |
103 install: build $(INSTALL_64) $(PROTOETCDIR)/zprofile $(PROTOETCDIR)/zshrc license |
109 |
104 |
110 # build does this always |
|
111 test: $(TEST_64) |
|
112 |
|
113 system-test: $(SYSTEM_TESTS_NOT_IMPLEMENTED) |
|
114 |
|
115 REQUIRED_PACKAGES += library/ncurses |
105 REQUIRED_PACKAGES += library/ncurses |
116 REQUIRED_PACKAGES += library/pcre |
106 REQUIRED_PACKAGES += library/pcre |
117 REQUIRED_PACKAGES += system/library |
|
118 REQUIRED_PACKAGES += system/library/math |
107 REQUIRED_PACKAGES += system/library/math |