build_makefile
来自「eCos/RedBoot for勤研ARM AnywhereII(4510) 含」· 代码 · 共 40 行
TXT
40 行
#! /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}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?