mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-02 04:13:34 +00:00
Sync to Wine-20050930:
Alexandre Julliard <[email protected]> - Fixed a number of pointer to integer conversions that wouldn't work right on a 64-bit platform. - Now that we are requiring bison anyway, make the .tab.c file use the same base name as the .y file, so that we can generate correct dependencies in all cases. svn path=/trunk/; revision=18327
This commit is contained in:
@@ -4,7 +4,6 @@ TOPOBJDIR = ../..
|
||||
SRCDIR = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
LEXOPT = -Cf #-w -b
|
||||
YACCOPT = #-v
|
||||
EXEEXT = @EXEEXT@
|
||||
|
||||
PROGRAMS = wrc$(EXEEXT)
|
||||
@@ -21,7 +20,7 @@ C_SRCS = \
|
||||
writeres.c
|
||||
|
||||
EXTRA_SRCS = parser.y parser.l
|
||||
EXTRA_OBJS = y.tab.o @[email protected]
|
||||
EXTRA_OBJS = parser.tab.o @[email protected]
|
||||
|
||||
all: $(PROGRAMS)
|
||||
|
||||
@@ -30,17 +29,17 @@ all: $(PROGRAMS)
|
||||
wrc$(EXEEXT): $(OBJS) $(LIBDIR)/wpp/libwpp.a
|
||||
$(CC) $(CFLAGS) -o $@ $(OBJS) -L$(LIBDIR) -lwpp -lwine_unicode -lwine_port $(LEXLIB) $(LDFLAGS)
|
||||
|
||||
y.tab.c y.tab.h: parser.y
|
||||
$(YACC) $(YACCOPT) -d -t $(SRCDIR)/parser.y
|
||||
parser.tab.c parser.tab.h: parser.y
|
||||
$(BISON) -d -t $(SRCDIR)/parser.y -o parser.tab.c
|
||||
|
||||
# hack to allow parallel make
|
||||
y.tab.h: y.tab.c
|
||||
y.tab.o: y.tab.h
|
||||
parser.tab.h: parser.tab.c
|
||||
parser.tab.o: parser.tab.h
|
||||
|
||||
@[email protected]: parser.l
|
||||
$(LEX) $(LEXOPT) -d -8 $(SRCDIR)/parser.l
|
||||
|
||||
@[email protected]: y.tab.h
|
||||
@[email protected]: parser.tab.h
|
||||
|
||||
install:: $(PROGRAMS)
|
||||
$(MKINSTALLDIRS) $(bindir) $(mandir)/man$(prog_manext)
|
||||
|
||||
@@ -7002,7 +7002,7 @@ char *yytext;
|
||||
#include "parser.h"
|
||||
#include "newstruc.h"
|
||||
|
||||
#include "y.tab.h"
|
||||
#include "parser.tab.h"
|
||||
|
||||
#define YY_USE_PROTOS
|
||||
#define YY_NO_UNPUT
|
||||
|
||||
@@ -819,8 +819,7 @@ static void handle_ani_list(riff_tag_t *lst, enum res_e type, int isswapped)
|
||||
isprint(rtp->tag[2]) ? rtp->tag[2] : '.',
|
||||
isprint(rtp->tag[3]) ? rtp->tag[3] : '.');
|
||||
|
||||
/* FIXME: This relies in sizeof(DWORD) == sizeof(pointer_type) */
|
||||
if((DWORD)rtp & 1)
|
||||
if((UINT_PTR)rtp & 1)
|
||||
rtp = SKIP_TAG(rtp,1);
|
||||
}
|
||||
}
|
||||
@@ -930,8 +929,7 @@ ani_curico_t *new_ani_curico(enum res_e type, raw_data_t *rd, int *memopt)
|
||||
isprint(rtp->tag[2]) ? rtp->tag[2] : '.',
|
||||
isprint(rtp->tag[3]) ? rtp->tag[3] : '.');
|
||||
|
||||
/* FIXME: This relies in sizeof(DWORD) == sizeof(pointer_type) */
|
||||
if((DWORD)rtp & 1)
|
||||
if((UINT_PTR)rtp & 1)
|
||||
rtp = SKIP_TAG(rtp,1);
|
||||
}
|
||||
|
||||
|
||||
@@ -109,7 +109,7 @@ cident [a-zA-Z_][0-9a-zA-Z_]*
|
||||
#include "parser.h"
|
||||
#include "newstruc.h"
|
||||
|
||||
#include "y.tab.h"
|
||||
#include "parser.tab.h"
|
||||
|
||||
#define YY_USE_PROTOS
|
||||
#define YY_NO_UNPUT
|
||||
|
||||
@@ -527,7 +527,7 @@ typedef union YYSTYPE {
|
||||
ani_any_t *ani;
|
||||
} YYSTYPE;
|
||||
/* Line 191 of yacc.c. */
|
||||
#line 531 "y.tab.c"
|
||||
#line 531 "parser.tab.c"
|
||||
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
|
||||
# define YYSTYPE_IS_DECLARED 1
|
||||
# define YYSTYPE_IS_TRIVIAL 1
|
||||
@@ -539,7 +539,7 @@ typedef union YYSTYPE {
|
||||
|
||||
|
||||
/* Line 214 of yacc.c. */
|
||||
#line 543 "y.tab.c"
|
||||
#line 543 "parser.tab.c"
|
||||
|
||||
#if ! defined (yyoverflow) || YYERROR_VERBOSE
|
||||
|
||||
@@ -4167,7 +4167,7 @@ yyreduce:
|
||||
}
|
||||
|
||||
/* Line 1000 of yacc.c. */
|
||||
#line 4171 "y.tab.c"
|
||||
#line 4171 "parser.tab.c"
|
||||
|
||||
yyvsp -= yylen;
|
||||
yyssp -= yylen;
|
||||
@@ -247,7 +247,7 @@ typedef union YYSTYPE {
|
||||
ani_any_t *ani;
|
||||
} YYSTYPE;
|
||||
/* Line 1275 of yacc.c. */
|
||||
#line 251 "y.tab.h"
|
||||
#line 251 "parser.tab.h"
|
||||
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
|
||||
# define YYSTYPE_IS_DECLARED 1
|
||||
# define YYSTYPE_IS_TRIVIAL 1
|
||||
@@ -44,7 +44,7 @@ WRC_SOURCES = $(addprefix $(WRC_BASE_), \
|
||||
utils.c \
|
||||
wrc.c \
|
||||
writeres.c \
|
||||
y.tab.c \
|
||||
parser.tab.c \
|
||||
lex.yy.c \
|
||||
port$(SEP)mkstemps.c \
|
||||
)
|
||||
@@ -104,7 +104,7 @@ $(WRC_INT_)writeres.o: $(WRC_BASE_)writeres.c | $(WRC_INT)
|
||||
$(ECHO_CC)
|
||||
${host_gcc} $(WRC_HOST_CFLAGS) -c $< -o $@
|
||||
|
||||
$(WRC_INT_)y.tab.o: $(WRC_BASE_)y.tab.c | $(WRC_INT)
|
||||
$(WRC_INT_)parser.tab.o: $(WRC_BASE_)parser.tab.c | $(WRC_INT)
|
||||
$(ECHO_CC)
|
||||
${host_gcc} $(WRC_HOST_CFLAGS) -c $< -o $@
|
||||
|
||||
|
||||
Reference in New Issue
Block a user