#124605 - beamer30 - Sat Apr 07, 2007 6:21 am
ok i can't seem to compile any file i always get 1 of two errors.
error 1 and makefile 1
heres the other one
is the code or is because im trying to compile in windows command line?
also do i have to compile with msys because if so i've got question about it too.
error 1 and makefile 1
Code: |
ERROR:
C:\Documents and Settings\Game Wizard\Desktop\keys_demo1>make arm-elf-g++ -g -Wall -O2 -mcpu=arm7tdmi -mtune=arm7tdmi -fomit-frame-pointer -ff ast-math -mthumb-interwork -I/c/devkitPro/libnds/include -DARM7 -c arm7_main.cpp -oarm7_main.o make: arm-elf-g++: Command not found make: *** [arm7_main.o] Error 127 C:\Documents and Settings\Game Wizard\Desktop\keys_demo1> MAKEFILE: # Makefile for keys_demo1.nds # chris.double@double.co.nz NDSLIB_INCLUDE=$(DEVKITPRO)/libnds/include NDSLIB_LIB=$(DEVKITPRO)/libnds/lib all: keys_demo1.nds.gba arm-eabi-gcc -g -c -Wall -O3 -mcpu=arm7tdmi -mtune=arm7tdmi -fomit-frame-pointer -ffast-math -mthumb -mthumb-interwork -Ic:/devkitPro/libgba/include characters.c -o characters.o arm7_main.o: arm7_main.cpp arm-elf-g++ -g -Wall -O2 -mcpu=arm7tdmi -mtune=arm7tdmi -fomit-frame-pointer -ffast-math -mthumb-interwork -I$(NDSLIB_INCLUDE) -DARM7 -c arm7_main.cpp -oarm7_main.o arm7.elf: arm7_main.o arm-elf-g++ -g -mthumb-interwork -mno-fpu -specs=ds_arm7.specs arm7_main.o -L$(NDSLIB_LIB) -lnds7 -oarm7.elf arm7.bin: arm7.elf arm-elf-objcopy -O binary arm7.elf arm7.bin arm9_main.o: arm9_main.cpp arm-elf-g++ -g -Wall -O2 -mcpu=arm9tdmi -mtune=arm9tdmi -fomit-frame-pointer -ffast-math -mthumb-interwork -I$(NDSLIB_INCLUDE) -DARM9 -c arm9_main.cpp -oarm9_main.o arm9.elf: arm9_main.o arm-elf-g++ -g -mthumb-interwork -mno-fpu -specs=ds_arm9.specs arm9_main.o -L$(NDSLIB_LIB) -lnds9 -o arm9.elf arm9.bin: arm9.elf arm-elf-objcopy -O binary arm9.elf arm9.bin keys_demo1.nds: arm7.bin arm9.bin ndstool -c keys_demo1.nds -9 arm9.bin -7 arm7.bin keys_demo1.nds.gba: keys_demo1.nds dsbuild keys_demo1.nds -o keys_demo1.nds.gba clean: rm -f *.bin rm -f *.elf rm -f *.o rm -f *~ |
heres the other one
Code: |
ERROR
C:\Documents and Settings\Game Wizard\Desktop\demo1>make basename: too many arguments Try `basename --help' for more information. make[1]: /c/Documents: No such file or directory make[1]: *** No rule to make target `/c/Documents'. Stop. make: *** [build] Error 2 C:\Documents and Settings\Game Wizard\Desktop\demo1> MAKEFILE #--------------------------------------------------------------------------------- .SUFFIXES: #--------------------------------------------------------------------------------- ifeq ($(strip $(DEVKITARM)),) $(error "Please set DEVKITARM in your environment. export DEVKITARM=<path to>devkitARM) endif include $(DEVKITARM)/ds_rules #--------------------------------------------------------------------------------- # TARGET is the name of the output # BUILD is the directory where object files & intermediate files will be placed # SOURCES is a list of directories containing source code # INCLUDES is a list of directories containing extra header files #--------------------------------------------------------------------------------- TARGET := $(shell basename $(CURDIR)) BUILD := build SOURCES := gfx source data INCLUDES := include build #--------------------------------------------------------------------------------- # options for code generation #--------------------------------------------------------------------------------- ARCH := -mthumb -mthumb-interwork # note: arm9tdmi isn't the correct CPU arch, but anything newer and LD # *insists* it has a FPU or VFP, and it won't take no for an answer! CFLAGS := -g -Wall -O2\ -mcpu=arm9tdmi -mtune=arm9tdmi -fomit-frame-pointer\ -ffast-math \ $(ARCH) CFLAGS += $(INCLUDE) -DARM9 CXXFLAGS := $(CFLAGS) -fno-rtti -fno-exceptions ASFLAGS := -g $(ARCH) LDFLAGS = -specs=ds_arm9.specs -g $(ARCH) -mno-fpu -Wl,-Map,$(notdir $*.map) #--------------------------------------------------------------------------------- # any extra libraries we wish to link with the project #--------------------------------------------------------------------------------- LIBS := -lnds9 #--------------------------------------------------------------------------------- # list of directories containing libraries, this must be the top level containing # include and lib #--------------------------------------------------------------------------------- LIBDIRS := $(LIBNDS) #--------------------------------------------------------------------------------- # no real need to edit anything past this point unless you need to add additional # rules for different file extensions #--------------------------------------------------------------------------------- ifneq ($(BUILD),$(notdir $(CURDIR))) #--------------------------------------------------------------------------------- export OUTPUT := $(CURDIR)/$(TARGET) export VPATH := $(foreach dir,$(SOURCES),$(CURDIR)/$(dir)) export DEPSDIR := $(CURDIR)/$(BUILD) CFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.c))) CPPFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.cpp))) SFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.s))) BINFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.bin))) #--------------------------------------------------------------------------------- # use CXX for linking C++ projects, CC for standard C #--------------------------------------------------------------------------------- ifeq ($(strip $(CPPFILES)),) #--------------------------------------------------------------------------------- export LD := $(CC) #--------------------------------------------------------------------------------- else #--------------------------------------------------------------------------------- export LD := $(CXX) #--------------------------------------------------------------------------------- endif #--------------------------------------------------------------------------------- export OFILES := $(BINFILES:.bin=.o) \ $(CPPFILES:.cpp=.o) $(CFILES:.c=.o) $(SFILES:.s=.o) export INCLUDE := $(foreach dir,$(INCLUDES),-I$(CURDIR)/$(dir)) \ $(foreach dir,$(LIBDIRS),-I$(dir)/include) \ $(foreach dir,$(LIBDIRS),-I$(dir)/include) \ -I$(CURDIR)/$(BUILD) export LIBPATHS := $(foreach dir,$(LIBDIRS),-L$(dir)/lib) .PHONY: $(BUILD) clean #--------------------------------------------------------------------------------- $(BUILD): @[ -d $@ ] || mkdir -p $@ @make --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile #--------------------------------------------------------------------------------- clean: @echo clean ... @rm -fr $(BUILD) $(TARGET).elf $(TARGET).nds $(TARGET).arm9 $(TARGET).ds.gba #--------------------------------------------------------------------------------- else DEPENDS := $(OFILES:.o=.d) #--------------------------------------------------------------------------------- # main targets #--------------------------------------------------------------------------------- $(OUTPUT).nds : $(OUTPUT).arm9 $(OUTPUT).arm9 : $(OUTPUT).elf $(OUTPUT).elf : $(OFILES) #--------------------------------------------------------------------------------- %.o : %.bin #--------------------------------------------------------------------------------- @echo $(notdir $<) $(bin2o) -include $(DEPENDS) #--------------------------------------------------------------------------------------- endif #--------------------------------------------------------------------------------------- |
is the code or is because im trying to compile in windows command line?
also do i have to compile with msys because if so i've got question about it too.