Browse Source

Add rule for compiling to asm

This allows commands of the form "make foo.s", which is useful
for inspecting the compiler output for debugging purposes.

Signed-off-by: Mans Rullgard <mans@mansr.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tags/n0.9
Mans Rullgard Michael Niedermayer 14 years ago
parent
commit
22aebf1bfe
2 changed files with 4 additions and 1 deletions
  1. +3
    -0
      common.mak
  2. +1
    -1
      subdir.mak

+ 3
- 0
common.mak View File

@@ -47,6 +47,9 @@ COMPILE_S = $(call COMPILE,AS)
%.o: %.cpp
$(COMPILE_CXX)

%.s: %.c
$(CC) $(CPPFLAGS) $(CFLAGS) -S -o $@ $<

%.o: %.S
$(COMPILE_S)



+ 1
- 1
subdir.mak View File

@@ -20,7 +20,7 @@ $(SUBDIR)x86/%.o: $(SUBDIR)x86/%.asm
$(YASMDEP) $(YASMFLAGS) -I $(<D)/ -M -o $@ $< > $(@:.o=.d)
$(YASM) $(YASMFLAGS) -I $(<D)/ -o $@ $<

$(OBJS) $(SUBDIR)%.ho $(TESTOBJS): CPPFLAGS += -DHAVE_AV_CONFIG_H
$(OBJS) $(OBJS:.o=.s) $(SUBDIR)%.ho $(TESTOBJS): CPPFLAGS += -DHAVE_AV_CONFIG_H
$(TESTOBJS): CPPFLAGS += -DTEST

$(SUBDIR)$(LIBNAME): $(OBJS)


Loading…
Cancel
Save