xref: /dpdk/examples/ptpclient/Makefile (revision ab129e90)
1*ab129e90SDaniel Mrzyglod#   BSD LICENSE
2*ab129e90SDaniel Mrzyglod#
3*ab129e90SDaniel Mrzyglod#   Copyright(c) 2015 Intel Corporation. All rights reserved.
4*ab129e90SDaniel Mrzyglod#   All rights reserved.
5*ab129e90SDaniel Mrzyglod#
6*ab129e90SDaniel Mrzyglod#   Redistribution and use in source and binary forms, with or without
7*ab129e90SDaniel Mrzyglod#   modification, are permitted provided that the following conditions
8*ab129e90SDaniel Mrzyglod#   are met:
9*ab129e90SDaniel Mrzyglod#
10*ab129e90SDaniel Mrzyglod#     * Redistributions of source code must retain the above copyright
11*ab129e90SDaniel Mrzyglod#       notice, this list of conditions and the following disclaimer.
12*ab129e90SDaniel Mrzyglod#     * Redistributions in binary form must reproduce the above copyright
13*ab129e90SDaniel Mrzyglod#       notice, this list of conditions and the following disclaimer in
14*ab129e90SDaniel Mrzyglod#       the documentation and/or other materials provided with the
15*ab129e90SDaniel Mrzyglod#       distribution.
16*ab129e90SDaniel Mrzyglod#     * Neither the name of Intel Corporation nor the names of its
17*ab129e90SDaniel Mrzyglod#       contributors may be used to endorse or promote products derived
18*ab129e90SDaniel Mrzyglod#       from this software without specific prior written permission.
19*ab129e90SDaniel Mrzyglod#
20*ab129e90SDaniel Mrzyglod#   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
21*ab129e90SDaniel Mrzyglod#   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22*ab129e90SDaniel Mrzyglod#   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
23*ab129e90SDaniel Mrzyglod#   A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
24*ab129e90SDaniel Mrzyglod#   OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
25*ab129e90SDaniel Mrzyglod#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
26*ab129e90SDaniel Mrzyglod#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27*ab129e90SDaniel Mrzyglod#   DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28*ab129e90SDaniel Mrzyglod#   THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29*ab129e90SDaniel Mrzyglod#   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30*ab129e90SDaniel Mrzyglod#   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31*ab129e90SDaniel Mrzyglod
32*ab129e90SDaniel Mrzyglodifeq ($(RTE_SDK),)
33*ab129e90SDaniel Mrzyglod$(error "Please define RTE_SDK environment variable")
34*ab129e90SDaniel Mrzyglodendif
35*ab129e90SDaniel Mrzyglod
36*ab129e90SDaniel Mrzyglod# Default target, can be overriddegitn by command line or environment
37*ab129e90SDaniel MrzyglodRTE_TARGET ?= x86_64-native-linuxapp-gcc
38*ab129e90SDaniel Mrzyglod
39*ab129e90SDaniel Mrzyglodinclude $(RTE_SDK)/mk/rte.vars.mk
40*ab129e90SDaniel Mrzyglod
41*ab129e90SDaniel Mrzyglod# binary name
42*ab129e90SDaniel MrzyglodAPP = ptpclient
43*ab129e90SDaniel Mrzyglod
44*ab129e90SDaniel Mrzyglod# all source are stored in SRCS-y
45*ab129e90SDaniel MrzyglodSRCS-y := ptpclient.c
46*ab129e90SDaniel Mrzyglod
47*ab129e90SDaniel MrzyglodCFLAGS += -O3
48*ab129e90SDaniel MrzyglodCFLAGS += $(WERROR_FLAGS)
49*ab129e90SDaniel Mrzyglod
50*ab129e90SDaniel Mrzyglod# workaround for a gcc bug with noreturn attribute
51*ab129e90SDaniel Mrzyglod# http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12603
52*ab129e90SDaniel Mrzyglodifeq ($(CONFIG_RTE_TOOLCHAIN_GCC),y)
53*ab129e90SDaniel MrzyglodCFLAGS_main.o += -Wno-return-type
54*ab129e90SDaniel Mrzyglodendif
55*ab129e90SDaniel Mrzyglod
56*ab129e90SDaniel Mrzyglodinclude $(RTE_SDK)/mk/rte.extapp.mk
57