Ignore:
Timestamp:
2013-11-13T05:53:37+01:00 (13 months ago)
Author:
moo
Message:

processor: avoid using srcdir dstdir marco for m4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/processor/main.m4

    r1472 r1473  
    1717define(`m4_len', defn(`len')) 
    1818undefine(`len') 
     19') 
     20define(`dirof', `patsubst(`$1', `[/\\][^/\\]*$', `')') 
     21ifdef(`__dir__', `', ` 
     22define(`__dir__', `dirof(__file__)') 
    1923') 
    2024define(`XCACHE_STRS', `($1), (sizeof($1))') 
     
    249253EXPORT_PROCESSOR(`dprint', `zval') 
    250254 
    251 include(srcdir`/processor/hashtable.m4') 
    252 include(srcdir`/processor/string.m4') 
    253 include(srcdir`/processor/struct.m4') 
    254 include(srcdir`/processor/process.m4') 
    255 include(srcdir`/processor/head.m4') 
    256  
    257 REDEF(`PROCESSOR_TYPE', `calc') include(srcdir`/processor/processor.m4') 
     255include(__dir__`/hashtable.m4') 
     256include(__dir__`/string.m4') 
     257include(__dir__`/struct.m4') 
     258include(__dir__`/process.m4') 
     259include(__dir__`/head.m4') 
     260 
     261REDEF(`PROCESSOR_TYPE', `calc') include(__dir__`/processor.m4') 
    258262 
    259263pushdef(`RELOCATE_EX', `$2 = ptradd($1 *, notnullable($2), processor->relocatediff);') 
    260 REDEF(`PROCESSOR_TYPE', `store') include(srcdir`/processor/processor.m4') 
     264REDEF(`PROCESSOR_TYPE', `store') include(__dir__`/processor.m4') 
    261265popdef(`RELOCATE_EX') 
    262266 
    263 REDEF(`PROCESSOR_TYPE', `restore') include(srcdir`/processor/processor.m4') 
     267REDEF(`PROCESSOR_TYPE', `restore') include(__dir__`/processor.m4') 
    264268 
    265269pushdef(`PTR_FROM_VIRTUAL_EX', `ptradd($1 *, notnullable($2), ptrdiff)') 
    266270pushdef(`RELOCATE_EX', `$2 = ptradd($1 *, notnullable($2), relocatediff);') 
    267271pushdef(`SRC', defn(`DST')) 
    268 REDEF(`PROCESSOR_TYPE', `relocate') include(srcdir`/processor/processor.m4') 
     272REDEF(`PROCESSOR_TYPE', `relocate') include(__dir__`/processor.m4') 
    269273popdef(`SRC') 
    270274popdef(`RELOCATE_EX') 
     
    272276 
    273277#ifdef HAVE_XCACHE_DPRINT 
    274 REDEF(`PROCESSOR_TYPE', `dprint') include(srcdir`/processor/processor.m4') 
     278REDEF(`PROCESSOR_TYPE', `dprint') include(__dir__`/processor.m4') 
    275279#endif /* HAVE_XCACHE_DPRINT */ 
    276280#ifdef HAVE_XCACHE_DISASSEMBLER 
    277 REDEF(`PROCESSOR_TYPE', `dasm') include(srcdir`/processor/processor.m4') 
     281REDEF(`PROCESSOR_TYPE', `dasm') include(__dir__`/processor.m4') 
    278282#endif /* HAVE_XCACHE_DISASSEMBLER */ 
    279283 
    280284undefine(`PROCESSOR_TYPE') 
    281285 
    282 include(srcdir`/processor/foot.m4') 
     286include(__dir__`/foot.m4') 
    283287 
    284288ifdef(`EXIT_PENDING', `m4exit(EXIT_PENDING)') 
Note: See TracChangeset for help on using the changeset viewer.