--- /dev/null
+#Makefile for BeRTOS test.
+#This makefile was generated automatically.
+
+V:= 0
+default: all
+
+include bertos/config.mk
+include ./app/test/avrtest.mk
+include ./app/test/armtest.mk
+include bertos/rules.mk
--- /dev/null
+#
+# $Id: armtest.mk 18234 2007-10-08 13:39:48Z rasky $
+# Copyright 2006 Develer S.r.l. (http://www.develer.com/)
+# All rights reserved.
+#
+# Makefile fragment for DevLib armtest application.
+#
+# Author: Bernardo Innocenti <bernie@develer.com>
+#
+#
+
+# Set to 1 for debug builds
+armtest_DEBUG = 1
+
+# Our target application
+TRG += armtest
+
+#include arm c and asm sources
+include ./app/test/arm_src.mk
+
+armtest_CSRC = $(arm_CSRC) app/test/empty_main.c
+
+armtest_CPPASRC = $(arm_ASRC)
+
+armtest_CROSS = arm-elf-
+
+armtest_CPPAFLAGS = -O0 -g -gdwarf-2 -g -gen-debug
+armtest_CPPFLAGS = -O0 -D'ARCH=0xFFFFFF' -D__ARM_AT91SAM7S256__ -g3 -gdwarf-2 -fverbose-asm -Iapp/test -Iapp/test/hw -Ibertos/cpu/arm
+armtest_LDFLAGS = #-nostartfiles -T bertos/cpu/arm/scripts/at91sam7_256_ram.ld -Wl,--no-warn-mismatch
+
+armtest_CPU = arm7tdmi
+
+# Debug stuff
+ifeq ($(armtest_DEBUG),1)
+ armtest_CFLAGS += -D_DEBUG
+endif
+
--- /dev/null
+#
+# $Id: avrtest.mk,v 1.3 2006/06/12 21:37:02 marco Exp $
+# Copyright 2006 Develer S.r.l. (http://www.develer.com/)
+# All rights reserved.
+#
+# Makefile fragment for DevLib avrtest application.
+#
+# Author: Bernardo Innocenti <bernie@develer.com>
+#
+
+
+
+# Set to 1 for debug builds
+avrtest_DEBUG = 1
+
+# Our target application
+TRG += avrtest
+
+avrtest_MCU = atmega64
+
+#include avr c and asm sources
+include app/test/avr_src.mk
+
+avrtest_CSRC = $(avr_CSRC) app/test/empty_main.c
+
+avrtest_CPPASRC = $(avr_ASRC)
+
+avrtest_PCSRC += bertos/mware/formatwr.c
+
+avrtest_CROSS = avr-
+avrtest_CPPFLAGS = -D'ARCH=1' -Iapp/test -Ibertos/cpu/avr -Ibertos/hw
+avrtest_CFLAGS = -Os -mcall-prologues -fno-strict-aliasing
+
+# Debug stuff
+ifeq ($(avrtest_DEBUG),1)
+ avrtest_CFLAGS += -D_DEBUG
+ avrtest_PCSRC += bertos/drv/kdebug.c
+endif
+
--- /dev/null
+/**
+ * \file
+ * <!--
+ * This file is part of BeRTOS.
+ *
+ * Bertos is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * As a special exception, you may use this file as part of a free software
+ * library without restriction. Specifically, if other files instantiate
+ * templates or use macros or inline functions from this file, or you compile
+ * this file and link it with other files to produce an executable, this
+ * file does not by itself cause the resulting executable to be covered by
+ * the GNU General Public License. This exception does not however
+ * invalidate any other reasons why the executable file might be covered by
+ * the GNU General Public License.
+ *
+ * Copyright 2008 Develer S.r.l. (http://www.develer.com/)
+ * All Rights Reserved.
+ * -->
+ *
+ * \brief Hardware-specific definitions
+ *
+ * \version $Id$
+ *
+ * \author Daniele Basile <asterix@develer.com>
+ */
+
+int main(void)
+{
+ for(;;)
+ {
+ }
+
+ return 0;
+}
--- /dev/null
+#!/bin/bash
+# This file is part of BeRTOS.
+#
+# Bertos is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+#
+# As a special exception, you may use this file as part of a free software
+# library without restriction. Specifically, if other files instantiate
+# templates or use macros or inline functions from this file, or you compile
+# this file and link it with other files to produce an executable, this
+# file does not by itself cause the resulting executable to be covered by
+# the GNU General Public License. This exception does not however
+# invalidate any other reasons why the executable file might be covered by
+# the GNU General Public License.
+#
+# Copyright 2008 Develer S.r.l. (http://www.develer.com/)
+#
+# Nighlty test for BeRTOS.
+#
+# Author Daniele Basile <asterix@develer.com>
+
+#Bertos dir, write with escape char for sed regrepx
+BERTOS_DIR_RE="\\.\\/bertos"
+
+#Test script dir, where are test script
+TEST_SCRIPT_DIR="test"
+
+#Test directory, where are the test makefile
+TEST_APP_DIR="app/test/"
+
+#Dir list for ARM, write with escape char for sed regrepx
+ARM_DRV="${BERTOS_DIR_RE}\\/cpu\\/arm\\/drv"
+ARM_DRV_C_EXCLUDE_LIST="ser_arm pwm_arm twi_arm stepper_arm"
+
+if [ $# \< 1 ] ; then
+ printf "You must specify a cpu target!\n\n"
+ printf "EXAMPLE:\n $0 <cpu target>\n\n"
+
+ exit 1
+fi
+
+#Get list of source for selected cpu target
+CSRC=`${TEST_SCRIPT_DIR}/get_source_list.sh $1 c`
+#ASRC=`${TEST_SCRIPT_DIR}/get_source_list.sh $1 s`
+ASRC=
+
+
+#Source to skip:
+if [ $1 = 'avr' ] ; then
+ CSRC=`echo $CSRC | sed "-e {s/${BERTOS_DIR_RE}\\/drv\\/kdebug\\.c//g}"`
+ CSRC=`echo $CSRC | sed "-e {s/${BERTOS_DIR_RE}\\/mware\\/formatwr\\.c//g}"`
+fi
+
+if [ $1 = 'arm' ] ; then
+ for i in $ARM_DRV_C_EXCLUDE_LIST ;
+ do
+ CSRC=`echo $CSRC | sed "-e {s/${ARM_DRV}\\/$i\\.c//g}"`
+ done
+fi
+
+
+
+printf "#This makefile was generate automatically.\n\n" > ${TEST_APP_DIR}/$1_src.mk
+printf "${1}_CSRC = $CSRC\n\n" >> ${TEST_APP_DIR}/$1_src.mk
+printf "${1}_ASRC = $ASRC\n\n" >> ${TEST_APP_DIR}/$1_src.mk
+
--- /dev/null
+#!/bin/bash
+# This file is part of BeRTOS.
+#
+# Bertos is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+#
+# As a special exception, you may use this file as part of a free software
+# library without restriction. Specifically, if other files instantiate
+# templates or use macros or inline functions from this file, or you compile
+# this file and link it with other files to produce an executable, this
+# file does not by itself cause the resulting executable to be covered by
+# the GNU General Public License. This exception does not however
+# invalidate any other reasons why the executable file might be covered by
+# the GNU General Public License.
+#
+# Copyright 2008 Develer S.r.l. (http://www.develer.com/)
+#
+# Nighlty test for BeRTOS.
+#
+# Author Daniele Basile <asterix@develer.com>
+
+#Directories
+BERTOS_DIR="./bertos"
+CPU_DIR="${BERTOS_DIR}/cpu"
+
+#Directory to exclude
+OS_DIR="${BERTOS_DIR}/os"
+EMUL_DIR="${BERTOS_DIR}/emul"
+APP_DIR="./app"
+
+if [ $# \< 2 ] ; then
+ printf "You must specify a cpu target, and source file type!\n"
+ printf "EXAMPLE:\n $0 <cpu target> <source type>\n\n"
+
+ exit 1
+fi
+
+#Create a list of source file whitout a cpu specific source
+GEN_SRC=`find . \( -name '\.svn' -prune -o -path $CPU_DIR -prune -o -path $APP_DIR -prune -o -path $OS_DIR -prune -o -path $EMUL_DIR -prune \) -o -name "*.${2}" -print | xargs`
+
+#Select c and asm sources for selected cpu target
+TRG_SRC=`find ${CPU_DIR}/${1} -name "\.svn" -prune -o -name "*.${2}" -print | xargs`
+
+#Generate a list of all source for each cpu
+SRC_ALL=${GEN_SRC}" "${TRG_SRC}
+
+
+printf "${SRC_ALL}"
+
--- /dev/null
+#!/bin/bash
+# This file is part of BeRTOS.
+#
+# Bertos is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+#
+# As a special exception, you may use this file as part of a free software
+# library without restriction. Specifically, if other files instantiate
+# templates or use macros or inline functions from this file, or you compile
+# this file and link it with other files to produce an executable, this
+# file does not by itself cause the resulting executable to be covered by
+# the GNU General Public License. This exception does not however
+# invalidate any other reasons why the executable file might be covered by
+# the GNU General Public License.
+#
+# Copyright 2008 Develer S.r.l. (http://www.develer.com/)
+#
+# Nighlty test for BeRTOS.
+#
+# Author Daniele Basile <asterix@develer.com>
+
+#Makefile test directory
+MAKEFILE_TEST_DIR="."
+TEST_DIR="test"
+
+#Cpu target that we want to test
+TRG="avr arm"
+
+for i in $TRG ;
+do
+ ${TEST_DIR}/gen_mk_src.sh $i
+done
+
+#Clean and launch make on all
+make -f ${MAKEFILE_TEST_DIR}/Makefile.test clean
+make -f ${MAKEFILE_TEST_DIR}/Makefile.test