blob: 479cf275407aa41d3bdeef12d73017b3a805be3a [file] [log] [blame]
#include "../Wine.tmpl"
MODULE = rc
.SUFFIXES: .rc
.rc.c:
echo "#include \"windows.h\"" >$*.rct
echo WINDOWS_H_ENDS_HERE >>$*.rct
cat $< >>$*.rct
$(CC) -E -x c -P $(CFLAGS) $*.rct | sed -e '1,/^WINDOWS_H_ENDS_HERE/d' | ./winerc -o $* -v -p $*
$(RM) $*.rct
XCOMM This would be nicer, but it breaks gcc (2.5.8 on Linux) --AJ
XCOMM gcc -E -x c -P $(CFLAGS) -imacros ../include/windows.h $*.rc | ./winerc -o $* -v -p $*
RCSRCS = sysres.rc
RCOBJS = $(RCSRCS:.rc=.o)
WineRelocatableTarget($(MODULE),,$(RCOBJS))
$(RCOBJS): winerc $(TOP)/include/windows.h
includes::
touch $(RCSRCS:.rc=.h)
clean::
$(RM) $(RCSRCS:.rc=.c) $(RCSRCS:.rc=.h)
XCOMM Rules to build the winerc program
SRCS = \
lex.yy.c \
winerc.c \
y.tab.c
OBJS = $(SRCS:.c=.o)
#ifdef SunArchitecture
YACC=bison -y
LEX=flex
LOCAL_LIBRARIES = -ly -ll
#endif
#if defined(i386BsdArchitecture) || defined(i386FreeBsd) || defined(FreeBSDArchitecture)
LOCAL_LIBRARIES = -ll
#endif
#ifdef LinuxArchitecture
LOCAL_LIBRARIES = -lfl
#endif
depend:: y.tab.c y.tab.h lex.yy.c
clean::
$(RM) lex.yy.c y.tab.*
ComplexProgramTarget(winerc)
y.tab.c y.tab.h: parser.y
$(YACC) -d -t parser.y
lex.yy.c: parser.l y.tab.h
$(LEX) -I parser.l