Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.
 
 
 
 
 
 

57 righe
1.7 KiB

  1. ##
  2. ## This file is part of the libopencm3 project.
  3. ##
  4. ## Copyright (C) 2014 Frantisek Burian <BuFran@seznam.cz>
  5. ##
  6. ## This library is free software: you can redistribute it and/or modify
  7. ## it under the terms of the GNU Lesser General Public License as published by
  8. ## the Free Software Foundation, either version 3 of the License, or
  9. ## (at your option) any later version.
  10. ##
  11. ## This library is distributed in the hope that it will be useful,
  12. ## but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. ## GNU Lesser General Public License for more details.
  15. ##
  16. ## You should have received a copy of the GNU Lesser General Public License
  17. ## along with this library. If not, see <http://www.gnu.org/licenses/>.
  18. ##
  19. ###############################################################################
  20. # The support makefile for GCC compiler toolchain, the rules part.
  21. #
  22. # please read mk/README for specification how to use this file in your project
  23. #
  24. %.bin: %.elf
  25. @printf " OBJCOPY $@\n"
  26. $(Q)$(OBJCOPY) -Obinary $< $@
  27. %.hex: %.elf
  28. @printf " OBJCOPY $@\n"
  29. $(Q)$(OBJCOPY) -Oihex $< $@
  30. %.srec: %.elf
  31. @printf " OBJCOPY $@\n"
  32. $(Q)$(OBJCOPY) -Osrec $< $@
  33. %.list: %.elf
  34. @printf " OBJDUMP $@\n"
  35. $(Q)$(OBJDUMP) -S $< > $@
  36. %.elf: $(OBJS) $(LDSCRIPT) $(LIBDEPS)
  37. @printf " LD $(*).elf\n"
  38. $(Q)$(LD) $(OBJS) $(LDLIBS) $(LDFLAGS) -T$(LDSCRIPT) $(ARCH_FLAGS) -o $@
  39. %.o: %.c
  40. @printf " CC $<\n"
  41. $(Q)$(CC) $(CFLAGS) $(CPPFLAGS) $(ARCH_FLAGS) -o $@ -c $<
  42. %.o: %.cxx
  43. @printf " CXX $<\n"
  44. $(Q)$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(ARCH_FLAGS) -o $@ -c $<
  45. %.o: %.cpp
  46. @printf " CXX $(*).cpp\n"
  47. $(Q)$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(ARCH_FLAGS) -o $@ -c $<