I've attached my corrected makefile (based on your suggestions). My changes (to 
${APPNAME}.c) at still not getting compiled in. Here is the order in which 
things happen when I do a make all:
1. Compiling... ...
2. Creating resource file...
3. Creating multigen files...
4. Creating sections.o file...
5. Linking files...
6. Building final prc...


-- 
For information on using the PalmSource Developer Forums, or to unsubscribe, 
please see http://www.palmos.com/dev/support/forums/
#########################################################
#
# Copyright (c) 2005, David Gnadinger.  All rights reserved.
#
# Title         : Makefile for SRS
#
# Author        : David Gnadinger
#
# Date          : 
#
# Edited        : 
#               : 
#
# Debugging     :
#
#########################################################

CC      = m68k-palmos-gcc

DEBUGFLAGS= -g -DDEBUG_BUILD -Wall
RELEASEFLAGS= -O1
APPNAME= srs

#Change the following from DEBUGFLAGS to RELEASEFLAGS accordingly.
DIR     = Debug
FLAGS   = -palmos5r3 ${DEBUGFLAGS}
#DIR    = Release
#FLAGS  = -palmos5r3 ${RELEASEFLAGS}

MULTIPLE_CODE_SECTIONS = TRUE

all : ${DIR}/${APPNAME}.prc

exe : ${DIR}/${APPNAME}.prc

clean :
        rm -f obj/*.bin obj/bin.res obj/*.grc ${DIR}/*.prc obj/*.o \
        obj/${APPNAME}.prc obj/${APPNAME} obj/*.s obj/*.ld \
        src/${APPNAME} 

fresh :
        make clean
        make all

obj/${APPNAME}.o : src/${APPNAME}.c res/${APPNAME}_res.h \
                themes/${APPNAME}.r src/${APPNAME}.h src/sections.h
        @echo "Compiling src/${APPNAME}.c..." && \
        ${CC} ${FLAGS} -c src/${APPNAME}.c -o obj/${APPNAME}.o

src/${APPNAME} : obj/${APPNAME}.o obj/${APPNAME}-sections.o \
                obj/${APPNAME}-sections.ld
        @echo "Linking files obj/${APPNAME}.o ... src/${APPNAME}." && \
        ${CC} ${FLAGS} obj/${APPNAME}.o obj/${APPNAME}-sections.o \
                -o src/${APPNAME} obj/${APPNAME}-sections.ld

obj/tFRM03e8.bin : res/${APPNAME}.rcp res/*.bmp
        @echo "Creating resource file..." && \
        cd res/ && \
        pilrc ${APPNAME}.rcp ../obj/
        cd ..

obj/${APPNAME}-sections.o: obj/${APPNAME}-sections.s
        @echo "Creating sections.o file..." && \
        cd obj/ && \
        ${CC} -c ${APPNAME}-sections.s
        cd ..

obj/${APPNAME}-sections.s obj/${APPNAME}-sections.ld: obj/${APPNAME}.def
        @echo "Creating multigen files..." && \
        cd obj/ && \
        m68k-palmos-multigen ${APPNAME}.def
        cd ..

#${DIR}/${APPNAME}.prc : obj/${APPNAME}.o \
#               obj/${APPNAME}-sections.s obj/${APPNAME}-sections.ld \
#               obj/${APPNAME}-sections.o obj/tFRM03e8.bin \
#               themes/*.bin src/${APPNAME}
#       @echo "Building final prc..." && \
#       build-prc -o $@ obj/${APPNAME}.def src/${APPNAME} -n "${APPNAME}" -c 
gna7 obj/*.bin themes/*.bin

${DIR}/${APPNAME}.prc : obj/${APPNAME}.o obj/tFRM03e8.bin \
                themes/*.bin src/${APPNAME}
        @echo "Building final prc..." && \
        build-prc -o $@ obj/${APPNAME}.def src/${APPNAME} -n "${APPNAME}" -c 
gna7 obj/*.bin themes/*.bin

Reply via email to