Paolo 'Blaisorblade' Giarrusso | 60b2737 | 2005-06-21 17:16:25 -0700 | [diff] [blame] | 1 | clean-files += unmap_tmp.o unmap_fin.o unmap.o |
| 2 | |
| 3 | ifdef CONFIG_MODE_TT |
| 4 | |
| 5 | #Always build unmap_fin.o |
| 6 | extra-y += unmap_fin.o |
| 7 | #Do dependency tracking for unmap.o (it will be always built, but won't get the tracking unless we use this). |
| 8 | targets += unmap.o |
| 9 | |
| 10 | #XXX: partially copied from arch/um/scripts/Makefile.rules |
| 11 | $(obj)/unmap.o: _c_flags = $(call unprofile,$(CFLAGS)) |
| 12 | |
| 13 | quiet_cmd_wrapld = LD $@ |
| 14 | define cmd_wrapld |
Al Viro | 13abf81 | 2005-09-03 15:57:31 -0700 | [diff] [blame] | 15 | $(LD) $(LDFLAGS) -r -o $(obj)/unmap_tmp.o $< ; \ |
Paolo 'Blaisorblade' Giarrusso | 20d0021 | 2005-07-14 00:33:43 -0700 | [diff] [blame] | 16 | $(OBJCOPY) $(UML_OBJCOPYFLAGS) $(obj)/unmap_tmp.o $@ -G switcheroo |
Paolo 'Blaisorblade' Giarrusso | 60b2737 | 2005-06-21 17:16:25 -0700 | [diff] [blame] | 17 | endef |
| 18 | |
| 19 | $(obj)/unmap_fin.o : $(obj)/unmap.o FORCE |
| 20 | $(call if_changed,wrapld) |
| 21 | |
| 22 | endif |