2017-03-26 07:02:34 +08:00
|
|
|
#******************************************************************************
|
2017-06-15 21:36:59 +08:00
|
|
|
# Makefile<build> 'build' project
|
2017-03-26 07:02:34 +08:00
|
|
|
#******************************************************************************
|
|
|
|
#
|
|
|
|
# File Description:
|
|
|
|
#
|
|
|
|
# A sample maefile for 'build'
|
|
|
|
#
|
|
|
|
#
|
|
|
|
#
|
|
|
|
#
|
|
|
|
#
|
|
|
|
#
|
|
|
|
#
|
|
|
|
#
|
|
|
|
#******************************************************************************
|
|
|
|
# (C) 2017 Christophe de Dinechin <christophe@dinechin.org>
|
|
|
|
# This software is licensed under the GNU General Public License v3
|
|
|
|
# See file COPYING for details.
|
|
|
|
#******************************************************************************
|
|
|
|
|
|
|
|
# Define the path to 'build' (can be a git submodule in your project)
|
|
|
|
BUILD=./
|
|
|
|
|
|
|
|
# Define the source code
|
|
|
|
SOURCES=hello.cpp
|
|
|
|
|
2017-07-01 18:48:08 +08:00
|
|
|
# Define libraries we use in that project
|
2017-11-30 16:40:35 +08:00
|
|
|
LIBRARIES=lib1/lib1.dll lib2/lib2.lib
|
2017-07-01 18:48:08 +08:00
|
|
|
|
2017-03-26 07:02:34 +08:00
|
|
|
# Define the product of the build (.exe will be removed for Unix builds)
|
|
|
|
PRODUCTS=hello.exe
|
|
|
|
|
2017-05-02 17:08:14 +08:00
|
|
|
# Define configuration options
|
2017-06-17 15:36:07 +08:00
|
|
|
CONFIG= <stdio.h> \
|
|
|
|
<unistd.h> \
|
|
|
|
<nonexistent.h> \
|
|
|
|
<sys/time.h> \
|
|
|
|
<sys/improbable.h> \
|
|
|
|
<iostream> \
|
|
|
|
clearenv \
|
|
|
|
libm \
|
|
|
|
liboony \
|
|
|
|
sbrk
|
2017-05-02 17:08:14 +08:00
|
|
|
|
2017-03-26 07:02:34 +08:00
|
|
|
# Define what to test
|
|
|
|
TESTS=product count-characters
|
|
|
|
|
|
|
|
# Define what to benchmark
|
|
|
|
BENCHMARKS=product
|
|
|
|
|
|
|
|
# Include the makefile rules
|
|
|
|
include $(BUILD)rules.mk
|
|
|
|
|
2017-06-15 21:36:59 +08:00
|
|
|
count-characters.test:
|
2017-11-08 23:10:51 +08:00
|
|
|
@echo Output has `$(TEST_ENV) $(OBJPRODUCTS) | wc -c` characters, should be 35
|