1 #
2 # This file and its contents are supplied under the terms of the
3 # Common Development and Distribution License ("CDDL"), version 1.0.
4 # You may only use this file in accordance with the terms of version
5 # 1.0 of the CDDL.
6 #
7 # A full copy of the text of the CDDL should have accompanied this
8 # source. A copy of the CDDL is also available via the Internet at
9 # http://www.illumos.org/license/CDDL.
10 #
11
12 #
13 # Copyright 2013 Nexenta Systems, Inc. All rights reserved.
14 #
15
16 PROG= acpiexec
17 OBJS= oslstubs.o
18 # common
19 OBJS += getopt.o acgetline.o
20
21 # components/debugger
22 OBJS += dbcmds.o dbdisply.o dbexec.o dbfileio.o dbhistry.o \
23 dbinput.o dbmethod.o dbnames.o dbstats.o dbutils.o \
24 dbxface.o dbconvert.o
25 # components/disassembler
26 OBJS += dmbuffer.o dmnames.o dmobject.o dmopcode.o dmresrc.o \
27 dmresrcl.o dmresrcs.o dmutils.o dmwalk.o dmdeferred.o \
28 dmresrcl2.o
29 # components/dispatcher
30 OBJS += dsargs.o dscontrol.o dsfield.o dsinit.o dsmethod.o \
31 dsmthdat.o dsobject.o dsopcode.o dsutils.o dswexec.o \
32 dswload.o dswload2.o dswscope.o dswstate.o
33 # components/events
34 OBJS += evevent.o evglock.o evgpe.o evgpeblk.o evgpeinit.o \
35 evgpeutil.o evmisc.o evregion.o evrgnini.o evsci.o \
36 evxface.o evxfevnt.o evxfgpe.o evxfregn.o evhandler.o
37 # components/executer
38 OBJS += exconfig.o exconvrt.o excreate.o exdebug.o exdump.o \
39 exfield.o exfldio.o exmisc.o exmutex.o exnames.o \
40 exoparg1.o exoparg2.o exoparg3.o exoparg6.o exprep.o \
41 exregion.o exresnte.o exresolv.o exresop.o exstore.o \
42 exstoren.o exstorob.o exsystem.o exutils.o
43 # components/hardware
44 OBJS += hwacpi.o hwgpe.o hwpci.o hwregs.o hwsleep.o hwvalid.o \
45 hwxface.o hwesleep.o hwxfsleep.o
46 # components/namespace
47 OBJS += nsaccess.o nsalloc.o nsdump.o nsdumpdv.o nseval.o \
48 nsinit.o nsload.o nsnames.o nsobject.o nsparse.o \
49 nspredef.o nsrepair.o nsrepair2.o nssearch.o nsutils.o \
50 nswalk.o nsxfeval.o nsxfname.o nsxfobj.o nsarguments.o \
51 nsconvert.o nsprepkg.o
52
53 # components/parser
54 OBJS += psargs.o psloop.o psopcode.o psparse.o psscope.o \
55 pstree.o psutils.o pswalk.o psxface.o psobject.o psopinfo.o
56 # components/resources
57 OBJS += rsaddr.o rscalc.o rscreate.o rsdump.o rsinfo.o rsio.o \
58 rsirq.o rslist.o rsmemory.o rsmisc.o rsutils.o \
59 rsxface.o rsdumpinfo.o rsserial.o
60 # components/tables
61 OBJS += tbfadt.o tbfind.o tbinstal.o tbutils.o tbxface.o \
62 tbxfroot.o tbprint.o tbxfload.o
63 # components/utilities
64 OBJS += utalloc.o utcache.o utcopy.o utdebug.o utdecode.o \
65 utdelete.o uteval.o utglobal.o utids.o utinit.o \
66 utlock.o utmath.o utmisc.o utmutex.o utobject.o \
67 utresrc.o utstate.o uttrack.o utosi.o utxferror.o \
68 utxface.o utaddress.o utbuffer.o uterror.o utexcep.o \
69 utownerid.o utpredef.o utstring.o utxfinit.o utxfmutex.o
70 # os_specific/service_layers
71 OBJS += osunixxf.o
72 # tools/acpiexec
73 OBJS += aeexec.o aehandlers.o aemain.o aetables.o
74
75 ACPICA= $(SRC)/common/acpica
76
77 include $(SRC)/cmd/Makefile.cmd
78
79 C99MODE= $(C99_ENABLE)
80 CPPFLAGS += -DACPI_EXEC_APP -I$(ACPICA)/include -I$(ACPICA)/compiler
81
82 .KEEP_STATE:
83
84 all: $(PROG)
85
86 clean:
87 $(RM) $(OBJS)
88
89 install: all $(ROOTPROG)
90
91 $(PROG): $(OBJS)
92 $(LINK.c) $(OBJS) -o $@ $(LDLIBS)
93 $(POST_PROCESS)
94
95 %.o: $(ACPICA)/common/%.c
96 $(COMPILE.c) -o $@ $<
97 $(POST_PROCESS_O)
98
99 %.o: $(ACPICA)/compiler/%.c
100 $(COMPILE.c) -o $@ $<
101 $(POST_PROCESS_O)
102
103 %.o: $(ACPICA)/components/debugger/%.c
104 $(COMPILE.c) -o $@ $<
105 $(POST_PROCESS_O)
106
107 %.o: $(ACPICA)/components/disassembler/%.c
108 $(COMPILE.c) -o $@ $<
109 $(POST_PROCESS_O)
110
111 %.o: $(ACPICA)/components/dispatcher/%.c
112 $(COMPILE.c) -o $@ $<
113 $(POST_PROCESS_O)
114
115 %.o: $(ACPICA)/components/events/%.c
116 $(COMPILE.c) -o $@ $<
117 $(POST_PROCESS_O)
118
119 %.o: $(ACPICA)/components/executer/%.c
120 $(COMPILE.c) -o $@ $<
121 $(POST_PROCESS_O)
122
123 %.o: $(ACPICA)/components/hardware/%.c
124 $(COMPILE.c) -o $@ $<
125 $(POST_PROCESS_O)
126
127 %.o: $(ACPICA)/components/namespace/%.c
128 $(COMPILE.c) -o $@ $<
129 $(POST_PROCESS_O)
130
131 %.o: $(ACPICA)/components/parser/%.c
132 $(COMPILE.c) -o $@ $<
133 $(POST_PROCESS_O)
134
135 %.o: $(ACPICA)/components/resources/%.c
136 $(COMPILE.c) -o $@ $<
137 $(POST_PROCESS_O)
138
139 %.o: $(ACPICA)/components/tables/%.c
140 $(COMPILE.c) -o $@ $<
141 $(POST_PROCESS_O)
142
143 %.o: $(ACPICA)/components/utilities/%.c
144 $(COMPILE.c) -o $@ $<
145 $(POST_PROCESS_O)
146
147 %.o: $(ACPICA)/os_specific/service_layers/%.c
148 $(COMPILE.c) -o $@ $<
149 $(POST_PROCESS_O)
150
151 %.o: $(ACPICA)/tools/acpiexec/%.c
152 $(COMPILE.c) -o $@ $<
153 $(POST_PROCESS_O)
154
155 include $(SRC)/cmd/Makefile.targ