Skip to content

Commit c75e143

Browse files
committed
Fix ecpg test building process to not generate *.dSYM junk on Macs.
The trick is to not try to build executables directly from .c files, but to always build the intermediate .o files. For obscure reasons, Darwin's version of gcc will leave debug cruft behind in the first case but not the second. Per complaint from Robert Haas.
1 parent 4b6623a commit c75e143

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/interfaces/ecpg/test/Makefile.regress

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@ override LIBS := -lecpg -lpgtypes $(filter -l%, $(libpq)) $(LIBS) $(PTHREAD_LIBS
88
ECPG = ../../preproc/ecpg --regression -I$(srcdir)/../../include
99

1010
%: %.c
11-
$(CC) $(CPPFLAGS) $(CFLAGS) $^ $(LDFLAGS) $(LDFLAGS_EX) $(LIBS) -o $@
11+
$(CC) $(CPPFLAGS) $(CFLAGS) -c $< -o $*.o
12+
$(CC) $(CPPFLAGS) $(CFLAGS) $*.o $(LDFLAGS) $(LDFLAGS_EX) $(LIBS) -o $@
1213

1314
%.c: %.pgc ../regression.h
1415
$(ECPG) -o $@ -I$(srcdir) $<

0 commit comments

Comments
 (0)