1# $NetBSD: Makefile,v 1.7 2013/12/28 16:03:51 christos Exp $ 2 3.if (${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "x86_64") 4PROG= iasl 5.endif 6BINDIR= /usr/bin 7MAN= iasl.8 8WARNS= 0 9TOPDIR= ${NETBSDSRCDIR}/sys/external/bsd/acpica/dist/compiler 10 11.include <bsd.own.mk> 12 13CPPFLAGS+= -I${TOPDIR}/../include -I${TOPDIR} -I. 14CPPFLAGS+= -D__NetBSD__ -DACPI_ASL_COMPILER -DACPI_USE_ALTERNATE_TIMEOUT 15CPPFLAGS+= -D_USE_BERKELEY_YACC 16.if ${MKREPRO:Uno} == "yes" 17CPPFLAGS+= -DACPI_REPRO 18.endif 19LDADD+= -ll -ly -lrt -lpthread 20DPADD+= ${LIBL} ${LIBY} ${LIBRT} ${LIBPTHREAD} 21 22DPSRCS= aslcompilerparse.c aslcompilerlex.c \ 23 dtparserparse.c dtparserlex.c prparserparse.c prparserlex.c 24 25.PATH: ${TOPDIR} 26SRCS+= \ 27 adfile.c \ 28 aslanalyze.c \ 29 aslbtypes.c \ 30 aslcodegen.c \ 31 aslcompile.c \ 32 aslcompilerlex.c \ 33 aslcompilerparse.c \ 34 aslerror.c \ 35 aslfileio.c \ 36 aslfiles.c \ 37 aslfold.c \ 38 aslhex.c \ 39 asllength.c \ 40 asllisting.c \ 41 asllistsup.c \ 42 aslload.c \ 43 asllookup.c \ 44 aslmain.c \ 45 aslmap.c \ 46 aslmethod.c \ 47 aslnamesp.c \ 48 asloffset.c \ 49 aslopcodes.c \ 50 asloperands.c \ 51 aslopt.c \ 52 asloptions.c \ 53 aslpredef.c \ 54 aslprepkg.c \ 55 aslresource.c \ 56 aslrestype1.c \ 57 aslrestype1i.c \ 58 aslrestype2.c \ 59 aslrestype2d.c \ 60 aslrestype2e.c \ 61 aslrestype2q.c \ 62 aslrestype2s.c \ 63 aslrestype2w.c \ 64 aslstartup.c \ 65 aslstubs.c \ 66 asltransform.c \ 67 asltree.c \ 68 aslutils.c \ 69 asluuid.c \ 70 aslwalks.c \ 71 aslxref.c \ 72 dtcompile.c \ 73 dtexpress.c \ 74 dtfield.c \ 75 dtio.c \ 76 dtparserlex.c \ 77 dtparserparse.c \ 78 dtsubtable.c \ 79 dttable.c \ 80 dttemplate.c \ 81 dtutils.c \ 82 prexpress.c \ 83 prmacros.c \ 84 prparserlex.c \ 85 prparserparse.c \ 86 prscan.c \ 87 prutils.c 88 89.PATH: ${TOPDIR}/../common 90SRCS+= \ 91 adisasm.c \ 92 adwalk.c \ 93 ahpredef.c \ 94 dmextern.c \ 95 dmrestag.c \ 96 dmtable.c \ 97 dmtbdump.c \ 98 dmtbinfo.c \ 99 getopt.c 100 101.PATH: ${TOPDIR}/../debugger 102SRCS+= dbfileio.c 103 104.PATH: ${TOPDIR}/../disassembler 105SRCS+= \ 106 dmbuffer.c \ 107 dmdeferred.c \ 108 dmnames.c \ 109 dmobject.c \ 110 dmopcode.c \ 111 dmresrc.c \ 112 dmresrcl.c \ 113 dmresrcl2.c \ 114 dmresrcs.c \ 115 dmutils.c \ 116 dmwalk.c 117 118.PATH: ${TOPDIR}/../dispatcher 119SRCS+= \ 120 dsargs.c \ 121 dscontrol.c \ 122 dsfield.c \ 123 dsobject.c \ 124 dsopcode.c \ 125 dsutils.c \ 126 dswexec.c \ 127 dswload.c \ 128 dswload2.c \ 129 dswscope.c \ 130 dswstate.c 131 132.PATH: ${TOPDIR}/../executer 133SRCS+= \ 134 exconvrt.c \ 135 excreate.c \ 136 exdump.c \ 137 exmisc.c \ 138 exmutex.c \ 139 exnames.c \ 140 exoparg1.c \ 141 exoparg2.c \ 142 exoparg3.c \ 143 exoparg6.c \ 144 exprep.c \ 145 exregion.c \ 146 exresnte.c \ 147 exresolv.c \ 148 exresop.c \ 149 exstore.c \ 150 exstoren.c \ 151 exstorob.c \ 152 exsystem.c \ 153 exutils.c 154 155.PATH: ${TOPDIR}/../parser 156SRCS+= \ 157 psargs.c \ 158 psloop.c \ 159 psobject.c \ 160 psopcode.c \ 161 psopinfo.c \ 162 psparse.c \ 163 psscope.c \ 164 pstree.c \ 165 psutils.c \ 166 pswalk.c 167 168.PATH: ${TOPDIR}/../tables 169SRCS+= \ 170 tbfadt.c \ 171 tbinstal.c \ 172 tbprint.c \ 173 tbutils.c \ 174 tbxface.c 175 176.PATH: ${TOPDIR}/../namespace 177SRCS+= \ 178 nsaccess.c \ 179 nsalloc.c \ 180 nsdump.c \ 181 nsnames.c \ 182 nsobject.c \ 183 nsparse.c \ 184 nssearch.c \ 185 nsutils.c \ 186 nswalk.c \ 187 nsxfobj.c \ 188 189.PATH: ${TOPDIR}/../utilities 190SRCS+= \ 191 utaddress.c \ 192 utalloc.c \ 193 utbuffer.c \ 194 utcache.c \ 195 utcopy.c \ 196 utdebug.c \ 197 utdecode.c \ 198 utdelete.c \ 199 uterror.c \ 200 utexcep.c \ 201 utglobal.c \ 202 utinit.c \ 203 utlock.c \ 204 utmath.c \ 205 utmisc.c \ 206 utmutex.c \ 207 utobject.c \ 208 utosi.c \ 209 utownerid.c \ 210 utpredef.c \ 211 utresrc.c \ 212 utstate.c \ 213 utstring.c \ 214 utxface.c \ 215 utxferror.c 216 217.PATH: ${TOPDIR}/../os_specific/service_layers 218SRCS+= osunixxf.c 219 220aslcompiler.y.h aslcompilerparse.c: ${TOPDIR}/aslcompiler.y 221 ${YACC} -v -d -o${.TARGET} -pAslCompiler ${.ALLSRC} 222 mv -f ${.PREFIX}.h aslcompiler.y.h 223 224aslcompilerlex.c: ${TOPDIR}/aslcompiler.l 225 ${LEX} -i -PAslCompiler -o${.TARGET} ${.ALLSRC} 226 227aslcompilerlex.o: aslcompiler.y.h 228 229dtparser.y.h dtparserparse.c: ${TOPDIR}/dtparser.y 230 ${YACC} -v -d -o${.TARGET} -pDtParser ${.ALLSRC} 231 mv -f ${.PREFIX}.h dtparser.y.h 232 233dtparserlex.c: ${TOPDIR}/dtparser.l 234 ${LEX} -i -PDtParser -o${.TARGET} ${.ALLSRC} 235 236dtparserlex.o: dtparser.y.h 237 238prparser.y.h prparserparse.c: ${TOPDIR}/prparser.y 239 ${YACC} -v -d -o${.TARGET} -pPrParser ${.ALLSRC} 240 mv -f ${.PREFIX}.h prparser.y.h 241 242prparserlex.c: ${TOPDIR}/prparser.l 243 ${LEX} -i -PPrParser -o${.TARGET} ${.ALLSRC} 244 245prparserlex.o: prparser.y.h 246 247CLEANFILES+= aslcompilerlex.c aslcompilerparse.c \ 248 aslcompiler.y.h aslcompilerparse.output \ 249 dtparserlex.c dtparserparse.c \ 250 dtparser.y.h dtparserparse.output \ 251 prparserlex.c prparserparse.c \ 252 prparser.y.h prparserparse.output \ 253 254.include <bsd.prog.mk> 255