Unbreak on amd64.

Obtained from:	debian (mptrace.c patch)
Sponsored by:	Sippy Software, Inc.
This commit is contained in:
Maxim Sobolev 2006-11-03 03:51:40 +00:00
parent 1e0bd18b8e
commit cebbabcf28
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=176251
2 changed files with 52 additions and 2 deletions

View file

@ -18,7 +18,7 @@ LIB_DEPENDS= elf.0:${PORTSDIR}/devel/libelf
WRKSRC= ${WRKDIR}/${PORTNAME}/build/unix
ONLY_FOR_ARCHS= i386
ONLY_FOR_ARCHS= i386 amd64
INSTALLS_SHLIB= yes
USE_GMAKE= yes
@ -42,6 +42,12 @@ DOCSIMG= cc1.eps cc1.jpg cc1.pdf \
test.eps test.jpg test.pdf \
trace.eps trace.jpg trace.pdf
.include <bsd.port.pre.mk>
.if ${ARCH} == "amd64"
CFLAGS+= -DENVIRON=\"ENVIRON_64\" -DMP_INIT_SUPPORT=0
.endif
do-install:
.for file in hexwords mpedit mpsym mupdate
${INSTALL_SCRIPT} ${WRKSRC}/../../bin/${file} ${PREFIX}/bin
@ -77,4 +83,4 @@ do-install:
.endfor
.endif
.include <bsd.port.mk>
.include <bsd.port.post.mk>

View file

@ -0,0 +1,44 @@
$FreeBSD$
--- ../../src/mptrace.c
+++ ../../src/mptrace.c
@@ -268,27 +268,27 @@
static XtResource resources[] =
{
{"alloc", XmCColor, XmRPixel, sizeof(Pixel),
- (Cardinal) &alcol, XmRString, (XtPointer) "black"},
+ (long) &alcol, XmRString, (XtPointer) "black"},
{"base", "Base", XmRInt, sizeof(void *),
- (Cardinal) &addrbase, XmRImmediate, (XtPointer) NULL},
+ (long) &addrbase, XmRImmediate, (XtPointer) NULL},
{"delay", "Delay", XmRInt, sizeof(unsigned long),
- (Cardinal) &delay, XmRImmediate, (XtPointer) 0},
+ (long) &delay, XmRImmediate, (XtPointer) 0},
{"free", XmCColor, XmRPixel, sizeof(Pixel),
- (Cardinal) &frcol, XmRString, (XtPointer) "white"},
+ (long) &frcol, XmRString, (XtPointer) "white"},
{"height", XmCHeight, XmRShort, sizeof(Dimension),
- (Cardinal) &height, XmRImmediate, (XtPointer) 512},
+ (long) &height, XmRImmediate, (XtPointer) 512},
{"internal", XmCColor, XmRPixel, sizeof(Pixel),
- (Cardinal) &incol, XmRString, (XtPointer) "red"},
+ (long) &incol, XmRString, (XtPointer) "red"},
{"space", "Space", XmRInt, sizeof(unsigned long),
- (Cardinal) &addrspace, XmRImmediate, (XtPointer) 4},
+ (long) &addrspace, XmRImmediate, (XtPointer) 4},
{"unalloc", XmCColor, XmRPixel, sizeof(Pixel),
- (Cardinal) &uncol, XmRString, (XtPointer) "blue"},
+ (long) &uncol, XmRString, (XtPointer) "blue"},
{"view-height", XmCHeight, XmRShort, sizeof(Dimension),
- (Cardinal) &vheight, XmRImmediate, (XtPointer) 256},
+ (long) &vheight, XmRImmediate, (XtPointer) 256},
{"view-width", XmCWidth, XmRShort, sizeof(Dimension),
- (Cardinal) &vwidth, XmRImmediate, (XtPointer) 256},
+ (long) &vwidth, XmRImmediate, (XtPointer) 256},
{"width", XmCWidth, XmRShort, sizeof(Dimension),
- (Cardinal) &width, XmRImmediate, (XtPointer) 512}
+ (long) &width, XmRImmediate, (XtPointer) 512}
};