zsh: update to 5.7.1 & native build
[unleashed-userland.git] / components / openindiana / nwam-manager / Makefile
blob8442bc7c1ca9fda0a55d7574abd385dac6012687
2 # This file and its contents are supplied under the terms of the
3 # Common Development and Distribution License ("CDDL)". You may
4 # only use this file in accordance with the terms of the CDDL.
6 # A full copy of the text of the CDDL should have accompanied this
7 # source. A copy of the CDDL is also available via the Internet at
8 # http://www.illumos.org/license/CDDL.
12 # Copyright 2013 Adam Stevko. All rights reserved.
13 # Copyright 2014 Alexander Pyhalov. All rights reserved.
16 include ../../../make-rules/shared-macros.mk
18 COMPONENT_NAME= nwam-manager
19 COMPONENT_SRC= $(COMPONENT_NAME)
20 COMPONENT_VERSION= 1.151.0
21 COMPONENT_LICENSE= CDDL
22 COMPONENT_LICENSE_FILE= COPYING
23 COMPONENT_FMRI= desktop/administration/nwam-manager
24 COMPONENT_CLASSIFICATION= System/Administration and Configuration
26 COMPONENT_REVISION=$(shell cd $(COMPONENT_SRC); git rev-list HEAD --count)
28 COMPONENT_SUMMARY= Network Auto-Magic User Interface
30 GIT=git
31 GIT_REPO=https://github.com/OpenIndiana/nwam-manager
32 GIT_BRANCH=oi/hipster
33 GIT_CHANGESET=HEAD
35 PATH=/usr/gnu/bin:/usr/bin
37 include $(WS_TOP)/make-rules/prep.mk
38 include $(WS_TOP)/make-rules/configure.mk
40 # The ugly hack with update-publish target is necessary to update
41 # source from git repository on each "gmake publish".
42 # publish: target should appear before inclusion of ips.mk
43 publish: update-publish
45 include $(WS_TOP)/make-rules/ips.mk
47 $(SOURCE_DIR)/.downloaded: $(ARCHIVES:%=$(USERLAND_ARCHIVES)%)
48 @[ -d $(SOURCE_DIR) ] || \
49 $(GIT) clone -b $(GIT_BRANCH) $(GIT_REPO) $(SOURCE_DIR)
50 @cd $(SOURCE_DIR) ; $(GIT) checkout $(GIT_BRANCH) ; $(GIT) pull \
51 $(GIT_REPO) ; $(GIT) log -1 --format=%H > .downloaded
53 COMPONENT_PREP_ACTION = \
54 (cd $(@D); libtoolize --copy --force && \
55 gnome-doc-prepare --force && \
56 intltoolize --force --copy --automake && \
57 aclocal -I m4 && \
58 autoheader && \
59 automake --add-missing --copy --force && \
60 autoconf)
62 # Missing include files in build dir without this.
63 COMPONENT_PRE_CONFIGURE_ACTION = ($(CLONEY) $(SOURCE_DIR) $(@D))
65 CONFIGURE_SCRIPT = $(@D)/configure
67 CONFIGURE_OPTIONS += --sysconfdir=/etc
68 CONFIGURE_OPTIONS += --libexecdir=/usr/lib
69 CONFIGURE_OPTIONS += --localstatedir=/var/lib
70 CONFIGURE_OPTIONS += --enable-private-nwam-headers
72 COMPONENT_INSTALL_ENV += GCONF_DISABLE_MAKEFILE_SCHEMA_INSTALL=1
74 update-publish:
75 @[ -d $(SOURCE_DIR) ] || \
76 $(GIT) clone -b $(GIT_BRANCH) $(GIT_REPO) $(SOURCE_DIR)
77 cd $(SOURCE_DIR) ; $(GIT) pull $(GIT_REPO) ; \
78 [ "$$($(GIT) log -1 --format=%H)" == "$$(cat .downloaded)" ] || \
79 ( $(GIT) log -1 --format=%H > .downloaded && $(MAKE) -C $$OLDPWD publish )
81 $(SOURCE_DIR)/.prep: $(SOURCE_DIR)/.downloaded Makefile
83 build: $(BUILD_32)
85 install: $(INSTALL_32)
87 download:: $(SOURCE_DIR)/.downloaded