Makefile.ds
changeset 5515 0fcf231a6e74
parent 5428 cff5d3cd5777
child 5536 05af1b9ff46d
     1.1 --- a/Makefile.ds	Fri Mar 25 14:45:04 2011 -0700
     1.2 +++ b/Makefile.ds	Sat Mar 26 21:26:05 2011 -0700
     1.3 @@ -17,7 +17,7 @@
     1.4  #---------------------------------------------------------------------------------
     1.5  TARGET		:=	$(shell basename $(CURDIR))
     1.6  BUILD		:=	src
     1.7 -SOURCES		:=	source
     1.8 +SOURCES		:=	src
     1.9  DATA		:=	data
    1.10  INCLUDES	:=	include
    1.11  
    1.12 @@ -53,7 +53,7 @@
    1.13  # list of directories containing libraries, this must be the top level containing
    1.14  # include and lib
    1.15  #---------------------------------------------------------------------------------
    1.16 -LIBDIRS	:=	$(LIBNDS)
    1.17 +LIBDIRS	:=	$(LIBNDS) $(PORTLIBS)
    1.18  
    1.19  #---------------------------------------------------------------------------------
    1.20  # no real need to edit anything past this point unless you need to add additional
    1.21 @@ -171,7 +171,8 @@
    1.22  
    1.23  export INCLUDE	:=	$(foreach dir,$(INCLUDES),-I$(CURDIR)/$(dir)) \
    1.24  			$(foreach dir,$(LIBDIRS),-I$(dir)/include) \
    1.25 -			-I$(CURDIR)/$(BUILD)
    1.26 +			-I$(CURDIR)/$(BUILD) \
    1.27 +			-I$(PORTLIBS)/include/SDL
    1.28  
    1.29  .PHONY: $(BUILD) clean all
    1.30  
    1.31 @@ -186,15 +187,15 @@
    1.32  	@$(MAKE) --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile.ds -s
    1.33  
    1.34  install: $(BUILD)
    1.35 -	@cp $(OUTPUT) $(DEVKITPRO)/libnds/lib/
    1.36 -	@mkdir -p $(DEVKITPRO)/libnds/include/SDL/
    1.37 -	@cp include/*.h $(DEVKITPRO)/libnds/include/SDL/
    1.38 +	@mkdir -p $(PORTLIBS)/include/SDL/
    1.39 +	@rsync -a $(OUTPUT) $(PORTLIBS)/lib/
    1.40 +	@rsync -a include/*.h $(PORTLIBS)/include/SDL/
    1.41  
    1.42  nds_test:
    1.43 -	$(MAKE) -C test/nds-test-progs
    1.44 +	$(MAKE) -C test/nds-test-progs -s
    1.45  
    1.46  tags:
    1.47 -	etags $(SRCS)
    1.48 +	cd $(SOURCES); etags $(CFILES)
    1.49  
    1.50  # This file must be compiled with the ARM instruction set, not
    1.51  # thumb. Use devkitpro way of doing things.
    1.52 @@ -206,6 +207,8 @@
    1.53  clean:
    1.54  	@echo clean ...
    1.55  	@cd src; rm -fr $(OFILES) $(OFILES:.o=.d) lib
    1.56 +	@rm -f $(OUTPUT)
    1.57 +	@make -C test/nds-test-progs -s clean
    1.58  
    1.59  #---------------------------------------------------------------------------------
    1.60  else