Make.defs 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. #
  2. # Licensed to the Apache Software Foundation (ASF) under one
  3. # or more contributor license agreements. See the NOTICE file
  4. # distributed with this work for additional information
  5. # regarding copyright ownership. The ASF licenses this file
  6. # to you under the Apache License, Version 2.0 (the
  7. # "License"); you may not use this file except in compliance
  8. # with the License. You may obtain a copy of the License at
  9. # * http://www.apache.org/licenses/LICENSE-2.0
  10. # * Unless required by applicable law or agreed to in writing,
  11. # software distributed under the License is distributed on an
  12. # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  13. # KIND, either express or implied. See the License for the
  14. # specific language governing permissions and limitations
  15. # under the License.
  16. #
  17. CFLAGS += \
  18. -I. \
  19. -I$(NIMBLE_ROOT)/nimble/include \
  20. -I$(NIMBLE_ROOT)/porting/npl/nuttx/include \
  21. -I$(NIMBLE_ROOT)/porting/npl/nuttx/src \
  22. -I$(NIMBLE_ROOT)/porting/nimble/include
  23. OSAL_PATH = $(NIMBLE_ROOT)/porting/npl/nuttx/src
  24. CSRCS = $(wildcard $(OSAL_PATH)/*.c) \
  25. $(wildcard $(OSAL_PATH)/*.cc) \
  26. $(NIMBLE_ROOT)/porting/nimble/src/os_mempool.c
  27. CXXOBJS += $($(wildcard *.cxx):$(CXXEXT)=$(SUFFIX)$(OBJEXT))
  28. CFLAGS += -DNIMBLE_CFG_CONTROLLER=0 -DOS_CFG_ALIGN_4=4 -DOS_CFG_ALIGNMENT=4
  29. DEPPATH += --dep-path $(NIMBLE_ROOT)/porting/npl/nuttx/test
  30. VPATH += :$(NIMBLE_ROOT)/porting/npl/nuttx/test
  31. VPATH += :$(NIMBLE_ROOT)/porting/nimble/src
  32. VPATH += :$(OSAL_PATH)
  33. PROGNAME = test_npl_task test_npl_eventq test_npl_callout test_npl_sem
  34. MAINSRC = $(wildcard $(NIMBLE_ROOT)/porting/npl/nuttx/test/*.c)
  35. clean::
  36. (cd $(NIMBLE_ROOT)/porting/npl/nuttx/test && rm -f *.o)
  37. (cd $(NIMBLE_ROOT)/porting/nimble/src && rm -f *.o)
  38. (cd $(OSAL_PATH) && rm -f *.o)
  39. test_npl_task.exe: test_npl_task.o $(OBJS)
  40. $(LD) -o $@ $^ $(LDFLAGS) $(LIBS)
  41. test_npl_eventq.exe: test_npl_eventq.o $(OBJS)
  42. $(LD) -o $@ $^ $(LDFLAGS) $(LIBS)
  43. test_npl_callout.exe: test_npl_callout.o $(OBJS)
  44. $(LD) -o $@ $^ $(LDFLAGS) $(LIBS)
  45. test_npl_sem.exe: test_npl_sem.o $(OBJS)
  46. $(LD) -o $@ $^ $(LDFLAGS) $(LIBS)