NetBSD/gnu/usr.bin/groff/Makefile.cfg

60 lines
1.3 KiB
INI

# Paths to libraries
.if exists($(.CURDIR)/../libgroff/obj)
LIBGROFF= $(.CURDIR)/../libgroff/obj/libgroff.a
.else
LIBGROFF= $(.CURDIR)/../libgroff/libgroff.a
.endif
.if exists($(.CURDIR)/../libdriver/obj)
LIBDRIVER= $(.CURDIR)/../libdriver/obj/libdriver.a
.else
LIBDRIVER= $(.CURDIR)/../libdriver/libdriver.a
.endif
.if exists($(.CURDIR)/../libbib/obj)
LIBBIB= $(.CURDIR)/../libbib/obj/libbib.a
.else
LIBBIB= $(.CURDIR)/../libbib/libbib.a
.endif
CFLAGS+= -DHAVE_UNISTD_H=1\
-DHAVE_DIRENT_H=1\
-DHAVE_LIMITS_H=1\
-DHAVE_STDLIB_H=1\
-DHAVE_SYS_DIR_H=1\
-DHAVE_CC_LIMITS_H=1\
-DHAVE_CC_UNISTD_H=1\
-DSTDLIB_H_DECLARES_GETOPT=1\
-DUNISTD_H_DECLARES_GETOPT=1\
-DSTDLIB_H_DECLARES_PUTENV=1\
-DRETSIGTYPE=void\
-DHAVE_MMAP=1\
-DHAVE_RENAME=1\
-DHAVE_MKSTEMP=1\
-DHAVE_SYS_SIGLIST=1\
-DARRAY_DELETE_NEEDS_SIZE=1
# Since we are still using gcc-1.X, we have to play games to ensure *.c
# files are compiled by gcc, *.cc files are compiled by g++, and everything
# is linked with g++.
CCC= gcc
CXX= g++
CC= $(CXX)
.SUFFIXES: .cc
.c.o:
$(CCC) $(CFLAGS) -c $(.IMPSRC)
.cc.o:
$(CXX) $(CFLAGS) -c $(.IMPSRC)
.y.cc:
$(YACC) $(YFLAGS) $(.IMPSRC)
mv y.tab.c $(.PREFIX).cc
mv y.tab.h $(.PREFIX).tab.h
# include dependancies
.if exists($(.CURDIR)/Makefile.dep)
.include "$(.CURDIR)/Makefile.dep"
.endif