# $MirOS: contrib/code/jupp/Makefile.bsd-wrapper,v 1.10 2017/07/08 15:38:43 tg Exp $ #- # make -f Makefile.bsd-wrapper CFPREFIX=/usr/mpkg sysconfjoesubdir=/joe MAN= joe.1 INST_TARGET= INSTALL_MAN= install CLEANFILES+= .deps charmap charmaps i18n syntax joe.1 joe.txt{,~} jupp CFPREFIX?= /usr/local .if ${CFPREFIX} == "/usr" CFMANDIR?= /usr/share/man .endif CFMANDIR?= ${CFPREFIX}/man CFETC?= /etc sysconfjoesubdir?=/jupp CFARGS+= --prefix=${CFPREFIX:Q} \ --bindir=${CFPREFIX:Q}/bin \ --mandir=${CFMANDIR:Q} \ --sysconfdir=${CFETC:Q} \ --enable-sysconfjoesubdir=${sysconfjoesubdir:Q} .ifmake winman CFARGS+= --enable-win32reloc .endif .include FSFISLIB= No .ifdef __CRAZY COPTS+= -Wno-unused-parameter \ -Wno-missing-field-initializers \ -Wno-old-style-definition -Wno-strict-prototypes \ -Wno-cast-qual \ -Wno-missing-prototypes -Wno-missing-declarations .endif joe.1: config.status cd ${FSFOBJDIR} && ${FSFMAKE} $@ all: jupplink jupplink: config.status @ln -sf joe jupp winman: joe.1 nrcon -mandoc joe.1 | col -bx >joe.txt~ print '$$-3,$$d\n,g/^MirOS BSD/.-3,.+10d\nwq' | ed -s joe.txt~ cat -s joe.txt~ | sed \ -e 's/\(jupp\)\( .global-options\)/\132\2/' \ -e '1d' -e '$$d' -e $$'s/$$/\r/' >joe.txt .ifmake joe.pdf V_GROFF!= pkg_info -e 'groff-*' V_GHOSTSCRIPT!= pkg_info -e 'ghostscript-*' . if empty(V_GROFF) || empty(V_GHOSTSCRIPT) . error empty V_GROFF=${V_GROFF} or V_GHOSTSCRIPT=${V_GHOSTSCRIPT} . endif .endif CLEANFILES+= joe.htm joe.ps1 joe.pdf CATS_KW= jmacs, joe, jpico, jstar, jupp, rjoe CATS_TITLE_joe_1=joe - Joe's Own Editor joe.htm: joe.cat1 set -e; . ${BSDSRCDIR:Q}/scripts/roff2htm; set_target_absolute; \ do_conversion_verbose joe 1 joe.cat1 joe.htm joe.pdf: joe.ps1 x=$$(ident joe.1 | \ awk '/Mir''OS:/ { print $$4$$5; }' | \ tr -dc 0-9); (( $${#x} == 14 )) || exit 1; exec \ ${MKSH} ${BSDSRCDIR:Q}/contrib/hosted/tg/ps2pdfmir -p pa4 -c \ -o joe.pdf '[' /Author '(The MirOS Project)' \ /Title '('${CATS_TITLE_joe_1:Q}')' \ /Subject '(BSD Reference Manual)' /ModDate "(D:$$x)" \ /Creator '(GNU groff version ${V_GROFF:S/groff-//} \(MirPorts\))' \ /Producer '(Artifex Ghostscript ${V_GHOSTSCRIPT:S/ghostscript-//:S/-artifex//} \(MirPorts\))' \ /Keywords '('${CATS_KW:Q}')' /DOCINFO pdfmark \ -f joe.ps1 .include