Subversion Repositories DevTools

Rev

Rev 291 | Rev 335 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 291 Rev 303
Line 1... Line 1...
1
# -*- mode: mak; -*-
1
# -*- mode: mak; -*-
2
###############################################################################
2
###############################################################################
3
# File:         TOOLSET/vcwin32.rul[e]
3
# File:         TOOLSET/vcwin32.rul[e]
4
# Contents:     Visual C/C++ WIN32 rules
4
# Contents:     Visual C/C++ WIN32 rules
5
#
5
#
6
# Version   Who      Date        Description#
-
 
7
#           APY      xx/08/99    Created
-
 
8
#                    22/03/00    NODEPDIRS
-
 
9
#                    30/06/01    V/C++ 6.0/CL 12.xx support
-
 
10
#                    23/08/01    Import INCLUDE and LIB
-
 
11
#                    12/03/04    mkdepend -b -o -p
-
 
12
#                    20/05/04    armerge -t
-
 
13
#                    04/10/04    PCLINT support
-
 
14
#
-
 
15
# $Source: /cvsroot/etm/devl/CFG/TOOLSET/VCWIN32.RUL,v $
-
 
16
# $Revision: 1.11 $ $Date: 2004/10/08 03:07:03 $ $State: Exp $
-
 
17
# $Author: ayoung $ $Locker:  $
-
 
18
#............................................................................#
-
 
19
 
-
 
20
###############################################################################
6
###############################################################################
21
#..     Remove "undef" warnings
7
#..     Remove "undef" warnings
22
#
8
#
23
cc_includes	+=
9
cc_includes	+=
24
cc_defines	+=
10
cc_defines	+=
Line 106... Line 92...
106
#		    - ';' seperated path list
92
#		    - ';' seperated path list
107
#		    - Uses \ as a dir sep
93
#		    - Uses \ as a dir sep
108
#		    - Uses real spaces in pathnames
94
#		    - Uses real spaces in pathnames
109
#..
95
#..
110
 
96
 
111
#
-
 
112
#   Work around for a bug in make 3.81 where abspath assumes that the input
-
 
113
#   is a relative path. The work around checks for paths that have a : or start
-
 
114
#   with a '/ - and assumes these are absolute.
-
 
115
#   It will only call makes 'abspath' for relative paths.
-
 
116
#
-
 
117
myabspath = $(foreach dir,$1,$(call myabs1path,$(dir)))
-
 
118
myabs1path = $(if $(or $(findstring :,$1),$(filter /%,$1)),$1,$(abspath $1))
-
 
119
 
-
 
120
vc_libs     := $(subst ;,$(space),$(subst \,/,$(subst $(space),$(spacealt),$(VC_LIB))))
97
vc_libs     := $(subst ;,$(space),$(subst \,/,$(subst $(space),$(spacealt),$(VC_LIB))))
121
ALL_LIBDIRS := $(wildcard $(call myabspath,$(LIBDIRS))) $(vc_libs)
98
ALL_LIBDIRS := $(wildcard $(call myabspath,$(LIBDIRS))) $(vc_libs)
122
LIB         := $(subst $(spacealt),$(space),$(subst $(space),$(empty),$(patsubst %,%;,$(subst /,\,$(ALL_LIBDIRS)))))
99
LIB         := $(subst $(spacealt),$(space),$(subst $(space),$(empty),$(patsubst %,%;,$(subst /,\,$(ALL_LIBDIRS)))))
123
export LIB
100
export LIB
124
 
101
 
Line 476... Line 453...
476
define as_pre
453
define as_pre
477
	@$(cmdfile) -wko$(as_cmdfile) "\
454
	@$(cmdfile) -wko$(as_cmdfile) "\
478
		$(patsubst %,%\\n,$(ASFLAGS)) \
455
		$(patsubst %,%\\n,$(ASFLAGS)) \
479
		$(patsubst %,%\\n,$(as_defines)) \
456
		$(patsubst %,%\\n,$(as_defines)) \
480
		$(patsubst %,$(as_i_switch)%\\n,$(subst /,\\\\,$(INCLUDES))) \
457
		$(patsubst %,$(as_i_switch)%\\n,$(subst /,\\\\,$(INCLUDES))) \
481
		$(patsubst %,$(as_i_switch)%\\n,$(subst /,\\\\,$(as_includes)))"
458
		$(patsubst %,$(as_i_switch)%\\n,$(subst /,\\\\,$(as_includes)))";\
-
 
459
	        $(call show_cmdfile,$(as_cmdfile))
482
endef
460
endef
483
 
461
 
484
ifndef LEAVETMP
462
ifndef LEAVETMP
485
define as_post
463
define as_post
486
	@$(rm) -f $(as_cmdfile)
464
	@$(rm) -f $(as_cmdfile)
Line 561... Line 539...
561
shld_term	=
539
shld_term	=
562
 
540
 
563
define shld_pre
541
define shld_pre
564
	@$(cmdfile) -wkWeo$(shld_cmdfile) \
542
	@$(cmdfile) -wkWeo$(shld_cmdfile) \
565
		"$(vc_ldflags) $($(notdir $(SHBASE))_shld)"; \
543
		"$(vc_ldflags) $($(notdir $(SHBASE))_shld)"; \
566
	echo [$@] Linking shared library ..;
544
	echo [$@] Linking shared library ..;\
-
 
545
        $(call show_cmdfile,$(shld_cmdfile))
567
endef
546
endef
568
 
547
 
569
ifndef LEAVETMP
548
ifndef LEAVETMP
570
define shld_post
549
define shld_post
571
	@$(rm) -f $(shld_cmdfile)
550
	@$(rm) -f $(shld_cmdfile)
Line 591... Line 570...
591
ld_term		=
570
ld_term		=
592
 
571
 
593
define ld_pre
572
define ld_pre
594
	@$(cmdfile) -wkWeo$(ld_cmdfile) \
573
	@$(cmdfile) -wkWeo$(ld_cmdfile) \
595
		"$(vc_ldflags) $($(notdir $(basename $@))_ld)"; \
574
		"$(vc_ldflags) $($(notdir $(basename $@))_ld)"; \
596
	echo [$@] Linking application ..
575
	echo [$@] Linking application ..;\
-
 
576
        $(call show_cmdfile,$(ld_cmdfile))
597
endef
577
endef
598
 
578
 
599
ifndef LEAVETMP
579
ifndef LEAVETMP
600
define ld_post
580
define ld_post
601
	@$(rm) -f $(ld_cmdfile)
581
	@$(rm) -f $(ld_cmdfile)