view examples/build_Makefile @ 1717:faaea4243d52

* cdl/redboot.cdl: Fixed the type of CYGNUM_REDBOOT_FLASH_BASE * src/flash.c (fis_[un]lock): Fix compiler warnings * src/flash.c (do_flash_init): Removed the MIPS br0ken condition which i wrongly added. My problem was actually a / 0. This roundup is needed otherwise the workspace goes off the end of the RAM.
author asl
date Mon, 16 Aug 2004 08:35:33 +0000
parents e68cf4daeda4
children
line wrap: on
line source

#! /bin/sh

# This script will create a generic Makefile template
# suitable for use with an installed eCos configuration.

# usage: <eCos_repository>/build_Makefile [<eCos_install_dir>]
# env:   ${SRCS} - the default list of source files
#        ${DST}  - the default target
ECOS_DIR=${1-`pwd`}

cat <<EOF >Makefile
#
# Makefile for eCos tests
#

# Platform specific setups
include Make.params

# Simple build rules

.c.o:
	\$(CC) -c \$(ECOS_GLOBAL_CFLAGS) -I\$(PREFIX)/include \$*.c

.o:
	\$(CC) \$(ECOS_GLOBAL_LDFLAGS) -L\$(PREFIX)/lib -Ttarget.ld \$*.o -o \$@

SRCS=${SRCS-source_file.c}
OBJS=\${SRCS:%.c=%.o}
DST=${DST-result_prog}

\${DST}: \${OBJS}

EOF

# Create actual parameters

`dirname $0`/build_Make.params ${ECOS_DIR}