Welcome! Log In Create A New Profile

Advanced

Stackdump when using makefile to convert pcm and mp3 files!

Posted by mdbrim 
Stackdump when using makefile to convert pcm and mp3 files!
June 21, 2009 01:50AM
what would cause this to happen:

> "make"
rotor.pcm
bin2s -a 32 /c/projects/wii/helo/data/rotor.pcm | powerpc-gekko-as -o rotor.pcm.o
echo "extern const u8" `(echo rotor.pcm | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"_end[];" > `(echo rotor.pcm | tr . _)`.h
0 [main] sh 27700 open_stackdumpfile: Dumping stack trace to sh.exe.stackdump
0 [main] sh 27856 open_stackdumpfile: Dumping stack trace to sh.exe.stackdump
echo "extern const u8" `(echo rotor.pcm | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"[];" >> `(echo rotor.pcm | tr . _)`.h
0 [main] sh 28212 open_stackdumpfile: Dumping stack trace to sh.exe.stackdump
echo "extern const u32" `(echo rotor.pcm | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`_size";" >> `(echo rotor.pcm | tr . _)`.h
0 [main] sh 27256 open_stackdumpfile: Dumping stack trace to sh.exe.stackdump
0 [main] sh 25736 open_stackdumpfile: Dumping stack trace to sh.exe.stackdump
Re: Stackdump when using makefile to convert pcm and mp3 files!
June 21, 2009 03:24AM
seriously... why would this happen?..

i think my Makefile is right:

#---------------------------------------------------------------------------------
# Clear the implicit built in rules
#---------------------------------------------------------------------------------
.SUFFIXES:
#---------------------------------------------------------------------------------
ifeq ($(strip $(DEVKITPPC)),)
$(error "Please set DEVKITPPC in your environment. export DEVKITPPC=devkitPPC")
endif

include $(DEVKITPPC)/wii_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
#---------------------------------------------------------------------------------
GRRLIB		:=  	../../GRRLIB
TARGET		:=		$(notdir $(CURDIR))
BUILD		:=		build
SOURCES		:=		source source/gfx $(GRRLIB)/GRRLIB $(GRRLIB)/lib/libpng/pngu $(GRRLIB)/lib/libjpeg
DATA		:=		data  
INCLUDES	:=

#---------------------------------------------------------------------------------
# options for code generation
#---------------------------------------------------------------------------------

CFLAGS	= -g -O2 -Wall $(MACHDEP) $(INCLUDE)
CXXFLAGS	=	$(CFLAGS)

LDFLAGS	=	-g $(MACHDEP) -Wl,-Map,$(notdir $@).map

#---------------------------------------------------------------------------------
# any extra libraries we wish to link with the project
#---------------------------------------------------------------------------------
LIBS	:=	-lwiisprite -lpng -lz -lfat -lwiiuse -lbte -lasnd -lm -ljpeg -lmad -logc

#---------------------------------------------------------------------------------
# list of directories containing libraries, this must be the top level containing
# include and lib
#---------------------------------------------------------------------------------
LIBDIRS	:= $(CURDIR)/$(GRRLIB)

#---------------------------------------------------------------------------------
# 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)) \
					$(foreach dir,$(DATA),$(CURDIR)/$(dir))

export DEPSDIR	:=	$(CURDIR)/$(BUILD)

#---------------------------------------------------------------------------------
# automatically build a list of object files for our project
#---------------------------------------------------------------------------------
CFILES		:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.c)))
CPPFILES	:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.cpp)))
sFILES		:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.s)))
SFILES		:=	$(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.S)))
BINFILES	:=	$(foreach dir,$(DATA),$(notdir $(wildcard $(dir)/*.*)))

#---------------------------------------------------------------------------------
# use CXX for linking C++ projects, CC for standard C
#---------------------------------------------------------------------------------
ifeq ($(strip $(CPPFILES)),)
	export LD	:=	$(CC)
else
	export LD	:=	$(CXX)
endif

export OFILES	:=	$(addsuffix .o,$(BINFILES)) \
					$(CPPFILES:.cpp=.o) $(CFILES:.c=.o) \
					$(sFILES:.s=.o) $(SFILES:.S=.o) $(OGGFILES:.ogg=.ogg.o)

#---------------------------------------------------------------------------------
# build a list of include paths
#---------------------------------------------------------------------------------
export INCLUDE	:=	$(foreach dir,$(INCLUDES), -iquote $(CURDIR)/$(dir)) \
					$(foreach dir,$(LIBDIRS),-I$(dir)/include) \
					-I$(CURDIR)/$(BUILD) \
					-I$(LIBOGC_INC)

#---------------------------------------------------------------------------------
# build a list of library paths
#---------------------------------------------------------------------------------
export LIBPATHS	:=	$(foreach dir,$(LIBDIRS),-L$(dir)/lib) \
					-L$(LIBOGC_LIB)

export OUTPUT	:=	$(CURDIR)/$(TARGET)
.PHONY: $(BUILD) clean

#---------------------------------------------------------------------------------
$(BUILD):
	@[ -d $@ ] || mkdir -p $@
	@make --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile

#---------------------------------------------------------------------------------
clean:
	@echo clean ...
	@rm -fr $(BUILD) $(OUTPUT).elf $(OUTPUT).dol

#---------------------------------------------------------------------------------
run:
	wiiload $(TARGET).dol


#---------------------------------------------------------------------------------
else

DEPENDS	:=	$(OFILES:.o=.d)

#---------------------------------------------------------------------------------
# main targets
#---------------------------------------------------------------------------------
$(OUTPUT).dol: $(OUTPUT).elf
$(OUTPUT).elf: $(OFILES)

#---------------------------------------------------------------------------------
# This rule links in binary data with the .jpg extension
#---------------------------------------------------------------------------------
%.jpg.o	: %.jpg
#---------------------------------------------------------------------------------
	@echo $(notdir $<)
	$(bin2o)

-include $(DEPENDS)

#---------------------------------------------------------------------------------
# This rule links in binary data with the .ogg extension
#---------------------------------------------------------------------------------
%.ogg.o	: %.ogg
#---------------------------------------------------------------------------------
	@echo $(notdir $<)
	$(bin2o)

-include $(DEPENDS)

#---------------------------------------------------------------------------------
# This rule links in binary data with the .pcm extension
#---------------------------------------------------------------------------------
%.pcm.o : %.pcm
#---------------------------------------------------------------------------------
	@echo $(notdir $<)
	$(bin2o)

-include $(DEPENDS)

#---------------------------------------------------------------------------------
# This rule links in binary data with the .mp3 extension
#---------------------------------------------------------------------------------
%.mp3.o : %.mp3
#---------------------------------------------------------------------------------
	@echo $(notdir $<)
	$(bin2o)

-include $(DEPENDS)

#---------------------------------------------------------------------------------
endif
#---------------------------------------------------------------------------------

Re: Stackdump when using makefile to convert pcm and mp3 files!
June 21, 2009 05:09AM
well... figured it out. After spamming #wiihelp, posting here, googling like mad, and troubleshooting for 4+ hours... someone suggested #wiidev...

120 seconds later this:

[22:56] do you have any logitech software on your machine?
[22:56] yeah
[22:56] that's what's causing it
[22:56] sec
[22:57] http://www.devkitpro.org/faq/why-does-make-often-crash-creating-a-shexestackdump-file-when-i-try-to-compile-my-source-code/
[23:02] WntrMute...
[23:02] OMFG... it works now
[23:02] * WntrMute bows
[23:02] unbelievable

SO, if anyone out there has same problems... hope that helps.

and thanks WntrMute
Re: Stackdump when using makefile to convert pcm and mp3 files!
June 21, 2009 05:23AM
Suffered from this problem a while back. Curse you Logitech!
Re: Stackdump when using makefile to convert pcm and mp3 files!
June 22, 2009 01:18AM
yeah that's crazy that having logitech (webcam) would cause that... and even more crazy that someone figured it out!
Sorry, only registered users may post in this forum.

Click here to login