source: trunk/openjdk/make/motif-rules.gmk@ 14

Last change on this file since 14 was 2, checked in by dmik, 15 years ago

Imported OpenJDK 6 b19 sources from Oracle.

File size: 3.4 KB
Line 
1#
2# Copyright 2001-2007 Sun Microsystems, Inc. All Rights Reserved.
3# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4#
5# This code is free software; you can redistribute it and/or modify it
6# under the terms of the GNU General Public License version 2 only, as
7# published by the Free Software Foundation. Sun designates this
8# particular file as subject to the "Classpath" exception as provided
9# by Sun in the LICENSE file that accompanied this code.
10#
11# This code is distributed in the hope that it will be useful, but WITHOUT
12# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14# version 2 for more details (a copy is included in the LICENSE file that
15# accompanied this code).
16#
17# You should have received a copy of the GNU General Public License version
18# 2 along with this work; if not, write to the Free Software Foundation,
19# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20#
21# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
22# CA 95054 USA or visit www.sun.com if you need additional information or
23# have any questions.
24#
25
26################################################################
27# MOTIF TARGETS
28################################################################
29
30motif-sanity:
31
32motif-freshen:
33 @$(call Freshen,$(MOTIF_MASTER),$(MOTIF_TOPDIR),$(MOTIF_SOURCE))
34
35ifeq ($(PLATFORM), linux)
36# LINUX vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv LINUX
37
38ifeq ($(BUILD_MOTIF), true)
39 dummy := $(shell $(MKDIR) -p $(MOTIF_DIR))
40 ABS_MOTIF_DIR :=$(call FullPath,$(MOTIF_DIR))
41endif
42
43MOTIF = $(MOTIF_LIB)/libXm.a
44
45MOTIF_BUILD_ARGUMENTS = \
46 PLATFORM=$(PLATFORM) \
47 ARCH_DATA_MODEL=$(ARCH_DATA_MODEL) \
48 ARCH=$(ARCH) \
49 ARCH_FAMILY=$(ARCH_FAMILY)
50
51motif: motif-build motif-install
52
53$(MOTIF): motif-build motif-install
54
55motif-build:
56 ( $(CD) $(MOTIF_TOPDIR)/lib/Xm && \
57 $(MAKE) $(MOTIF_BUILD_ARGUMENTS) all )
58 ( $(CD) $(MOTIF_TOPDIR)/lib/Xm && \
59 $(MAKE) $(MOTIF_BUILD_ARGUMENTS) includes )
60
61motif-install: motif-install-lib motif-install-include
62
63motif-install-lib: $(MOTIF_LIB)
64 $(RM) $(MOTIF_LIB)/libXm.a
65 ( $(CD) $(MOTIF_LIB) && \
66 $(LN) -s $(ABS_MOTIF_TOPDIR)/lib/libXm.a . )
67
68motif-install-include: $(MOTIF_DIR)/include
69 $(RM) $(MOTIF_DIR)/include/Xm
70 ( $(CD) $(MOTIF_DIR)/include && \
71 $(LN) -s $(ABS_MOTIF_TOPDIR)/lib/Xm/exports/include/Xm . )
72
73#
74# clobber the build, but note that the motif code misses some
75# clobber files in $(MOTIF_TOPDIR), so clean them up too.
76# Also, remove the staging area - $(MOTIF_DIR)
77#
78motif-clobber:
79 ( $(CD) $(MOTIF_TOPDIR)/lib/Xm && \
80 $(MAKE) $(MOTIF_BUILD_ARGUMENTS) clean )
81 $(RM) $(MOTIF_TOPDIR)/lib/libXm.a
82 $(RM) $(MOTIF_TOPDIR)/lib/Xm/Xm.msg
83 $(RM) -r $(MOTIF_TOPDIR)/lib/Xm/exports
84 $(RM) -r $(MOTIF_LIB)
85 $(RM) -r $(MOTIF_DIR)/include
86 $(RM) -r $(MOTIF_DIR)
87 $(RM) $(MOTIF_TOPDIR)/include
88
89$(MOTIF_DIR) $(MOTIF_LIB) $(MOTIF_DIR)/include:
90 $(MKDIR) -p $@
91
92# LINUX ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ LINUX
93else
94# NON-LINUX vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv NON-LINUX
95
96motif:
97
98motif-clobber:
99
100.PHONY: motif motif-build motif-install motif-install-lib \
101 motif-sanity motif-freshen motif-install-include motif-clobber
102
103
104# NON-LINUX ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ NON-LINUX
105endif
Note: See TracBrowser for help on using the repository browser.