117 lines
2.9 KiB
Makefile
117 lines
2.9 KiB
Makefile
|
#
|
||
|
# Makefile.config
|
||
|
#
|
||
|
# Common configuration and setup file to generate the ACPICA tools and
|
||
|
# utilities: the iASL compiler, acpiexec, acpihelp, acpinames, acpisrc,
|
||
|
# acpixtract, acpibin.
|
||
|
#
|
||
|
# This file is included by the individual makefiles for each tool.
|
||
|
#
|
||
|
|
||
|
#
|
||
|
# Note: This makefile is intended to be used from within the native
|
||
|
# ACPICA directory structure, from under generate/unix. It specifically
|
||
|
# places all object files in a generate/unix subdirectory, not within
|
||
|
# the various ACPICA source directories. This prevents collisions
|
||
|
# between different compilations of the same source file with different
|
||
|
# compile options, and prevents pollution of the source code.
|
||
|
#
|
||
|
|
||
|
#
|
||
|
# Configuration
|
||
|
# Notes:
|
||
|
# gcc should be version 4 or greater, otherwise some of the options
|
||
|
# used will not be recognized.
|
||
|
# Global optimization flags (such as -O2, -Os) are not used, since
|
||
|
# they cause issues on some compilers.
|
||
|
# The _GNU_SOURCE symbol is required for many hosts.
|
||
|
#
|
||
|
PROGS = acpibin acpiexec acpihelp acpinames acpisrc acpixtract iasl
|
||
|
|
||
|
HOST = _CYGWIN
|
||
|
CC = gcc
|
||
|
COMPILE = $(CC) -c $(CFLAGS) $(CWARNINGFLAGS) -o$@ $?
|
||
|
|
||
|
#
|
||
|
# Common defines
|
||
|
#
|
||
|
ACPICA_SRC = ../../../source
|
||
|
ACPICA_COMMON = $(ACPICA_SRC)/common
|
||
|
ACPICA_CORE = $(ACPICA_SRC)/components
|
||
|
ACPICA_TOOLS = $(ACPICA_SRC)/tools
|
||
|
ACPICA_OSL = $(ACPICA_SRC)/os_specific/service_layers
|
||
|
ASL_COMPILER = $(ACPICA_SRC)/compiler
|
||
|
COPYPROG = @mkdir -p ../bin; rm -f ../bin/$(PROG); cp --remove-destination $(PROG) ../bin
|
||
|
INSTALLDIR = /usr/bin
|
||
|
INSTALLPROG = cp --remove-destination $(PROG) $(INSTALLDIR)
|
||
|
#
|
||
|
# Common compiler flags. The warning flags in addition to -Wall are not
|
||
|
# automatically included in -Wall.
|
||
|
#
|
||
|
CFLAGS += \
|
||
|
-D$(HOST) \
|
||
|
-D_GNU_SOURCE \
|
||
|
-I$(ACPICA_SRC)/include
|
||
|
|
||
|
CWARNINGFLAGS = \
|
||
|
-ansi \
|
||
|
-Wall \
|
||
|
-Wbad-function-cast \
|
||
|
-Wdeclaration-after-statement \
|
||
|
-Werror \
|
||
|
-Wformat=2 \
|
||
|
-Wmissing-declarations \
|
||
|
-Wmissing-prototypes \
|
||
|
-Wstrict-aliasing=0 \
|
||
|
-Wstrict-prototypes \
|
||
|
-Wswitch-default \
|
||
|
-Wpointer-arith \
|
||
|
-Wundef
|
||
|
|
||
|
#
|
||
|
# gcc 4+ flags
|
||
|
#
|
||
|
CWARNINGFLAGS += \
|
||
|
-Waddress \
|
||
|
-Waggregate-return \
|
||
|
-Wchar-subscripts \
|
||
|
-Wempty-body \
|
||
|
-Wlogical-op \
|
||
|
-Wmissing-declarations \
|
||
|
-Wmissing-field-initializers \
|
||
|
-Wmissing-parameter-type \
|
||
|
-Wnested-externs \
|
||
|
-Wold-style-declaration \
|
||
|
-Wold-style-definition \
|
||
|
-Wredundant-decls \
|
||
|
-Wtype-limits
|
||
|
|
||
|
#
|
||
|
# Extra warning flags (possible future use)
|
||
|
#
|
||
|
#CWARNINGFLAGS += \
|
||
|
# -Wcast-qual \
|
||
|
# -Wconversion
|
||
|
# -Wshadow \
|
||
|
|
||
|
#
|
||
|
# Bison/Flex configuration
|
||
|
#
|
||
|
# -v: verbose, produces a .output file
|
||
|
# -d: produces the defines header file
|
||
|
# -y: act like yacc
|
||
|
#
|
||
|
# -i: generate case insensitive scanner
|
||
|
# -s: suppress default rule, abort on unknown input
|
||
|
#
|
||
|
# Berkeley yacc configuration
|
||
|
#
|
||
|
#YACC= byacc
|
||
|
#YFLAGS += -v -d
|
||
|
#
|
||
|
YACC= bison
|
||
|
YFLAGS += -v -d -y
|
||
|
|
||
|
LEX= flex
|
||
|
LFLAGS += -i -s
|