]> git.saurik.com Git - apple/libc.git/blame - Makefile.obsd_end
Libc-498.tar.gz
[apple/libc.git] / Makefile.obsd_end
CommitLineData
3d9156a7
A
1# For the OpenBSD auto patching mechanism and compatibility environment
2# setup, original OpenBSD sources a put into a OpenBSD subdirectory.
3# If a file with the same name, but suffix ".patch" is in that directory,
4# that patch will be applied before use.
5#
6# The OBSDMDSRCS, OBSDMISRCS, OBSDORIGHDRS and OBSDSRCS variables must be set,
7# and bracketed by .include of Makefile.obsd_begin and Makefile.obsd_end
8#
9# Set up dependencies between the OpenBSD source (in a OpenBSD subdirectory)
10# and a file with a -obsd.x suffix (where x is 'c' or 's'). The suffix
11# rules will then compile the file with the simulate OpenBSD environment.
12
13OBSDSECTIONS= 1 2 3 4 5 6 7 8 9
14
15.for _src in ${OBSDSRCS}
224c7076
A
16.ifmake autopatch
17${_src:R}-obsd.${_src:E}: OpenBSD/${_src} _AUTOPATCHCUR
18AUTOPATCHSRCS+= ${_src:R}-obsd.${_src:E}
19.else # !autopatch
3d9156a7 20SRCS+= ${_src}
224c7076 21.endif # autopatch
3d9156a7
A
22.endfor
23
24.for _src in ${OBSDMDSRCS}
224c7076
A
25.ifmake autopatch
26${_src:R}-obsd.${_src:E}: OpenBSD/${_src} _AUTOPATCHCUR
27AUTOPATCHSRCS+= ${_src:R}-obsd.${_src:E}
28.else # !autopatch
3d9156a7 29MDSRCS+= ${_src}
224c7076 30.endif # autopatch
3d9156a7
A
31.endfor
32
33.for _src in ${OBSDMISRCS}
224c7076
A
34.ifmake autopatch
35${_src:R}-obsd.${_src:E}: OpenBSD/${_src} _AUTOPATCHCUR
36AUTOPATCHSRCS+= ${_src:R}-obsd.${_src:E}
37.else # !autopatch
3d9156a7 38MISRCS+= ${_src}
224c7076 39.endif # autopatch
3d9156a7
A
40.endfor
41
224c7076 42.ifmake autopatch
3d9156a7 43.for _src in ${OBSDHDRS}
224c7076
A
44${_src}: OpenBSD/${_src} _AUTOPATCHCUR
45AUTOPATCHHDRS+= ${_src}
3d9156a7 46.endfor
224c7076 47.endif # autopatch
3d9156a7
A
48
49.for _sect in ${OBSDSECTIONS}
50.for _src in ${OBSDMAN${_sect}}
224c7076 51.ifmake autopatch
3d9156a7 52${_src}: OpenBSD/${_src} _AUTOPATCH
3d9156a7 53AUTOPATCHMAN+= ${_src}
224c7076
A
54.else # !autopatch
55MAN${_sect}+= ${_src}
56.endif # autopatch
3d9156a7
A
57.endfor
58.endfor