summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjpierre%netscape.com <devnull@localhost>2003-03-28 02:35:39 +0000
committerjpierre%netscape.com <devnull@localhost>2003-03-28 02:35:39 +0000
commitc820e8dd4a2b2a3e5b2fbe3ab0a626f9b2c11bdd (patch)
treefa79123ea3dd0801208647d802d5cd9a4448c674
parenta01400a888bb8d3c6145dc7e123fccfb91472bcb (diff)
downloadnss-hg-c820e8dd4a2b2a3e5b2fbe3ab0a626f9b2c11bdd.tar.gz
Fix for bug 105271 - compile source files with full pathnames on Windows & OS/2 to help debugging. r=wtc
-rw-r--r--security/coreconf/rules.mk24
1 files changed, 20 insertions, 4 deletions
diff --git a/security/coreconf/rules.mk b/security/coreconf/rules.mk
index ac55f9279..1191c6d72 100644
--- a/security/coreconf/rules.mk
+++ b/security/coreconf/rules.mk
@@ -383,14 +383,22 @@ WCCFLAGS3 := $(subst -D,-d,$(WCCFLAGS2))
$(OBJDIR)/$(PROG_PREFIX)%$(OBJ_SUFFIX): %.c
@$(MAKE_OBJDIR)
ifdef USE_NT_C_SYNTAX
- $(CC) -Fo$@ -c $(CFLAGS) $<
+ifeq ($(OS_TARGET),OS2)
+ $(CC) -Fo$@ -c $(CFLAGS) $(if $(findstring :,$<),$<,$(shell pwd)/$<)
+else
+ $(CC) -Fo$@ -c $(CFLAGS) $(if $(findstring :,$<),$<,$(shell pwd | sed -e 's|/cygdrive/\(.\)/|\1:/|g;')/$<)
+endif
else
$(CC) -o $@ -c $(CFLAGS) $<
endif
$(PROG_PREFIX)%$(OBJ_SUFFIX): %.c
ifdef USE_NT_C_SYNTAX
- $(CC) -Fo$@ -c $(CFLAGS) $<
+ifeq ($(OS_TARGET),OS2)
+ $(CC) -Fo$@ -c $(CFLAGS) $(if $(findstring :,$<),$<,$(shell pwd)/$<)
+else
+ $(CC) -Fo$@ -c $(CFLAGS) $(if $(findstring :,$<),$<,$(shell pwd | sed -e 's|/cygdrive/\(.\)/|\1:/|g;')/$<)
+endif
else
$(CC) -o $@ -c $(CFLAGS) $<
endif
@@ -418,7 +426,11 @@ $(OBJDIR)/$(PROG_PREFIX)%$(OBJ_SUFFIX): %.S
$(OBJDIR)/$(PROG_PREFIX)%: %.cpp
@$(MAKE_OBJDIR)
ifdef USE_NT_C_SYNTAX
- $(CCC) -Fo$@ -c $(CFLAGS) $<
+ifeq ($(OS_TARGET),OS2)
+ $(CCC) -Fo$@ -c $(CFLAGS) $(if $(findstring :,$<),$<,$(shell pwd)/$<)
+else
+ $(CCC) -Fo$@ -c $(CFLAGS) $(if $(findstring :,$<),$<,$(shell pwd | sed -e 's|/cygdrive/\(.\)/|\1:/|g;')/$<)
+endif
else
$(CCC) -o $@ -c $(CFLAGS) $<
endif
@@ -438,7 +450,11 @@ ifdef STRICT_CPLUSPLUS_SUFFIX
rm -f $(OBJDIR)/t_$*.cc
else
ifdef USE_NT_C_SYNTAX
- $(CCC) -Fo$@ -c $(CFLAGS) $<
+ifeq ($(OS_TARGET),OS2)
+ $(CCC) -Fo$@ -c $(CFLAGS) $(if $(findstring :,$<),$<,$(shell pwd)/$<)
+else
+ $(CCC) -Fo$@ -c $(CFLAGS) $(if $(findstring :,$<),$<,$(shell pwd | sed -e 's|/cygdrive/\(.\)/|\1:/|g;')/$<)
+endif
else
$(CCC) -o $@ -c $(CFLAGS) $<
endif