openmotif4 stable port information

Package: openmotif4
Version: 2.3.2
Revision: 3
#Source: ftp://ftp.ics.com/openmotif/2.3/%v/openmotif-%v.tar.gz
Source: http://www.motifzone.net/files/public_downloads/openmotif/2.3/%v/openmotif-%v.tar.gz
Source-MD5: bf5479d52bc114d299200ec20e463e96
PatchFile: %n.patch
PatchFile-MD5: 717492a63f8ad51d716f08d46a756a9b
PatchScript: <<
patch -p1 < %{PatchFile}
perl -pi.bak -e 's,-flat_namespace -undefined suppress,-undefined dynamic_lookup,g' configure
perl -pi.bak -e "s;recipient's;recipients;" tools/wml/motif.wml
perl -pi -e 's/hardcode_direct=yes/hardcode_direct=no/g' configure
perl -pi -e "s|iconv_open|libiconv_open|g" configure
<<
BuildDepends: x11-dev, libjpeg, libpng3, libiconv-dev, fink (>= 0.24.12)
Depends: x11, %N-shlibs (= %v-%r), libjpeg-shlibs, libpng3-shlibs, libiconv
Conflicts: lesstif, lesstif-dev, openmotif3
Replaces: lesstif, lesstif-dev, openmotif3
BuildDependsOnly: True
SourceDirectory: openmotif-%v
NoSetMAKEFLAGS: true
SetCFLAGS: -I%p/include -DXNO_MTSAFE_STRINGAPI -DXNO_MTSAFE_PWDAPI -DXNO_MTSAFE_TIMEAPI
SetLIBS: -L%p/lib -L/usr/X11R6/lib -lXt
SetMAKEFLAGS: -j1
ConfigureParams: --mandir=%p/share/man --enable-jpeg --with-libjpeg-includes=%p/include --with-libjpeg-lib=%p/lib -enable-png --with-libpng-includes=%p/include --with-libpng-lib=%p/lib --enable-xft --x-includes=/usr/X11R6/include --x-libraries=/usr/X11R6/lib --enable-static RANLIB='ranlib -c' --build=%m-apple-darwin`uname -r|cut -f1 -d.` --host=%m-apple-darwin`uname -r|cut -f1 -d.`
CompileScript: <<
./configure %c
make
<<
InstallScript: <<
make install DESTDIR=%d
<<
DocFiles: BUGREPORT COPYRIGHT.MOTIF LICENSE README RELEASE RELNOTES TODO
SplitOff: <<
Package: %N-shlibs
Depends: x11
# when lesstif is upgraded to lesstif3 (motif 2.2) this will conflict
# Conflicts: lesstif3-shlibs
Files: lib/libXm.*.dylib lib/libUil.*.dylib lib/libMrm.*.dylib
DocFiles: COPYRIGHT.MOTIF LICENSE
Shlibs: <<
%p/lib/libXm.4.dylib 5.0.0 %n (>= 2.3.0-1)
%p/lib/libUil.4.dylib 5.0.0 %n (>= 2.3.0-1)
%p/lib/libMrm.4.dylib 5.0.0 %n (>= 2.3.0-1)
<<
<<
SplitOff2: <<
Package: %N-bin
Depends: %N-shlibs (= %v-%r)
Conflicts: lesstif-bin, openmotif3-bin
Replaces: lesstif-bin, openmotif3-bin
Files: bin share/man/man1 share/man/man4 lib/X11
DocFiles: COPYRIGHT.MOTIF LICENSE
<<
PostInstScript: <<
update-alternatives --install %p/share/man/man3/Object.3 Object.3 %p/share/man/man3/Object.3.openmotif 65
<<
PreRmScript: <<
if [ $1 != "upgrade" ]; then
update-alternatives --remove Object.3 %p/share/man/man3/Object.3.openmotif
fi
<<
#
Description: Official Implementation of OSF/Motif
DescDetail: <<
OpenMotif is a more "official" implementation of Motif. Some apps
behave better with openmotif, but lesstif's license is less restrictive.

OpenMotif 2.2.3 is considered a stable release.
<<
DescUsage: <<
Clients which link both libXm and libXt from XFree86 >= 4.2 might need
to use the -force_flat_namespace linker flag (to avoid errors of the
form "Error: attempt to add non-widget child .. " upon launch).
<<
DescPackaging: <<
This package provides version 2.2 of the motif API. (libraries versioned "3")
Thus, it will not conflict with lesstif-shlibs until lesstif is upgraded to v3 libs.

man pages that conflict with other packages are managed with update-alternatives.

Restrictive license only allows openmotif to be used with open-source operating systems.
OSX is considered one of these, so binary distribution is allowed.

Binary distribution is OK, confirmed with message from openmotif.

Need DYLD_LIBRARY_PATH so that the wmldbcreate executable finds
libXm.3.dylib in the build directory.

Package rev 2: removed force_flat_namespace and added X11 CPP flag to prevent
possible build failure. Version bumped due to namespace change.

Package rev 3: Remove that X11 include directory as it causes problems in apps that link Xm.

More recent changes:

dmacks fixed flag ordering (in Makefiles and in this old libtool) to
see local files in preference to installed ones and (thanks pogma!)
avoid DYLD_ games.

Cleaner manpage installation.

Patch configure and Makefile.in's to find fink headers and libraries
before those in /usr/X11R6.
<<
License: Restrictive/Distributable
Homepage: http://www.opengroup.org/openmotif/
Maintainer: Jack Howarth

openmotif4 stable port .patch

--- openmotif-2.3.1/tools/wml/Makefile.in.orig 2008-12-28 16:45:10.000000000 -0500
+++ openmotif-2.3.1/tools/wml/Makefile.in 2008-12-28 16:50:19.000000000 -0500
@@ -72,10 +72,10 @@
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(CPPFLAGS) $(AM_CFLAGS)
LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
- $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS)
CCLD = $(CC)
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
@@ -268,7 +268,7 @@
wml_LDADD = -L. -lwml
wml_DEPENDENCIES = libwml.a
wmldbcreate_LDADD = ../../lib/Xm/libXm.la
-INCLUDES = -I../../lib -I$(srcdir)/../../lib -I$(srcdir)/../../include ${X_CFLAGS}
+INCLUDES = -I../../lib -I$(srcdir)/../../lib -I$(srcdir)/../../include ${CFLAGS} ${X_CFLAGS}
noinst_LIBRARIES = libwml.a
libwml_a_SOURCES = wmlparse.y wml.c wmloutkey.c wmlouth.c wmloutmm.c wmloutp1.c wmlresolve.c wmlsynbld.c wmlutils.c
all: all-am
@@ -373,18 +373,18 @@
@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $<

wmldbcreate.o: $(srcdir)/wmldbcreate.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT wmldbcreate.o -MD -MP -MF $(DEPDIR)/wmldbcreate.Tpo -c -o wmldbcreate.o `test -f '$(srcdir)/wmldbcreate.c' || echo '$(srcdir)/'`$(srcdir)/wmldbcreate.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) -MT wmldbcreate.o -MD -MP -MF $(DEPDIR)/wmldbcreate.Tpo -c -o wmldbcreate.o `test -f '$(srcdir)/wmldbcreate.c' || echo '$(srcdir)/'`$(srcdir)/wmldbcreate.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/wmldbcreate.Tpo $(DEPDIR)/wmldbcreate.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/wmldbcreate.c' object='wmldbcreate.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o wmldbcreate.o `test -f '$(srcdir)/wmldbcreate.c' || echo '$(srcdir)/'`$(srcdir)/wmldbcreate.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) -c -o wmldbcreate.o `test -f '$(srcdir)/wmldbcreate.c' || echo '$(srcdir)/'`$(srcdir)/wmldbcreate.c

wmldbcreate.obj: $(srcdir)/wmldbcreate.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT wmldbcreate.obj -MD -MP -MF $(DEPDIR)/wmldbcreate.Tpo -c -o wmldbcreate.obj `if test -f '$(srcdir)/wmldbcreate.c'; then $(CYGPATH_W) '$(srcdir)/wmldbcreate.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/wmldbcreate.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) -MT wmldbcreate.obj -MD -MP -MF $(DEPDIR)/wmldbcreate.Tpo -c -o wmldbcreate.obj `if test -f '$(srcdir)/wmldbcreate.c'; then $(CYGPATH_W) '$(srcdir)/wmldbcreate.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/wmldbcreate.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/wmldbcreate.Tpo $(DEPDIR)/wmldbcreate.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(srcdir)/wmldbcreate.c' object='wmldbcreate.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o wmldbcreate.obj `if test -f '$(srcdir)/wmldbcreate.c'; then $(CYGPATH_W) '$(srcdir)/wmldbcreate.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/wmldbcreate.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) -c -o wmldbcreate.obj `if test -f '$(srcdir)/wmldbcreate.c'; then $(CYGPATH_W) '$(srcdir)/wmldbcreate.c'; else $(CYGPATH_W) '$(srcdir)/$(srcdir)/wmldbcreate.c'; fi`

.l.c:
$(am__skiplex) $(SHELL) $(YLWRAP) $< $(LEX_OUTPUT_ROOT).c $@ -- $(LEXCOMPILE)
--- openmotif-2.3.1/lib/Mrm/Makefile.in.orig 2008-09-19 10:55:04.000000000 -0400
+++ openmotif-2.3.1/lib/Mrm/Makefile.in 2008-12-28 16:54:05.000000000 -0500
@@ -72,10 +72,10 @@
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(CPPFLAGS) $(AM_CFLAGS)
LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
- $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS)
CCLD = $(CC)
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
@@ -232,7 +232,7 @@
MAINTAINERCLEANFILES = Makefile.in
CLEANFILES = $(BUILT_SOURCES)
EXTRA_DIST = Mrm.msg Imakefile
-INCLUDES = -I$(srcdir)/.. -I.. -I../Xm ${X_CFLAGS}
+INCLUDES = -I$(srcdir)/.. -I.. -I../Xm ${CFLAGS} ${X_CFLAGS}
mrmdir = $(includedir)/Mrm
libMrm_la_LIBADD = ../Xm/libXm.la ${X_LIBS} -lXt ${X_PRE_LIBS} -lX11 ${X_EXTRA_LIBS}
lib_LTLIBRARIES = libMrm.la
@@ -309,7 +309,7 @@
rm -f "$${dir}/so_locations"; \
done
libMrm.la: $(libMrm_la_OBJECTS) $(libMrm_la_DEPENDENCIES)
- $(LINK) -rpath $(libdir) $(libMrm_la_OBJECTS) $(libMrm_la_LIBADD) $(LIBS)
+ $(LINK) -rpath $(libdir) $(libMrm_la_OBJECTS) $(LIBS) $(libMrm_la_LIBADD)

mostlyclean-compile:
-rm -f *.$(OBJEXT)
--- openmotif-2.3.1/lib/Xm/Makefile.in.orig 2008-09-19 10:55:05.000000000 -0400
+++ openmotif-2.3.1/lib/Xm/Makefile.in 2008-12-28 16:58:32.000000000 -0500
@@ -159,10 +159,10 @@
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(CPPFLAGS) $(AM_CFLAGS)
LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
- $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS)
CCLD = $(CC)
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
@@ -344,7 +344,7 @@
INCLUDES = -I.. -I$(srcdir)/.. -DXMBINDDIR_FALLBACK=\"@XMBINDDIR_FALLBACK@\" \
-DINCDIR=\"@INCDIR@\" \
-DLIBDIR=\"@LIBDIR@\" \
- ${X_CFLAGS}
+ ${CFLAGS} ${X_CFLAGS}

xmdir = $(includedir)/Xm
lib_LTLIBRARIES = libXm.la
@@ -669,7 +669,7 @@
rm -f "$${dir}/so_locations"; \
done
libXm.la: $(libXm_la_OBJECTS) $(libXm_la_DEPENDENCIES)
- $(LINK) -rpath $(libdir) $(libXm_la_OBJECTS) $(libXm_la_LIBADD) $(LIBS)
+ $(LINK) -rpath $(libdir) $(libXm_la_OBJECTS) $(LIBS) $(libXm_la_LIBADD)

mostlyclean-compile:
-rm -f *.$(OBJEXT)
--- openmotif-2.3.1/clients/uil/Makefile.in.orig 2008-09-19 10:54:58.000000000 -0400
+++ openmotif-2.3.1/clients/uil/Makefile.in 2008-12-28 17:03:11.000000000 -0500
@@ -96,10 +96,10 @@
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(CPPFLAGS) $(AM_CFLAGS)
LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
- $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS)
CCLD = $(CC)
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
@@ -265,7 +265,7 @@
-I$(srcdir)/../../tools/wml \
-I../../include \
-I../../lib \
- -I../../tools/wml ${X_CFLAGS}
+ -I../../tools/wml ${CFLAGS} ${X_CFLAGS}

BUILT_SOURCES = UilParser.c UilLexPars.c UilDBDef.h
CLEANFILES = UilParser.c UilLexPars.c UilDBDef.h
--- openmotif-2.3.1/config/util/Makefile.in.orig 2008-09-19 10:54:58.000000000 -0400
+++ openmotif-2.3.1/config/util/Makefile.in 2008-12-28 17:10:31.000000000 -0500
@@ -54,10 +54,10 @@
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(CPPFLAGS) $(AM_CFLAGS)
LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
- $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS)
CCLD = $(CC)
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
@@ -217,7 +217,7 @@
mkdirhier.man mkdirhier.sh mkshadow syminst.sh x11mf.sh \
xmkmf.cpp xmkmf.man Makefile.ini

-INCLUDES = ${X_CFLAGS}
+INCLUDES = ${CFLAGS} ${X_CFLAGS}
all: all-am

.SUFFIXES:
--- openmotif-2.3.1/Makefile.in.orig 2008-09-19 10:55:05.000000000 -0400
+++ openmotif-2.3.1/Makefile.in 2008-12-28 16:45:10.000000000 -0500
@@ -245,8 +245,7 @@
include \
tools \
clients \
- doc \
- demos
+ doc

AUTOMAKE_OPTIONS = 1.4
ACLOCAL_AMFLAGS = -I .
--- openmotif-2.3.1/configure.orig 2008-09-19 10:54:56.000000000 -0400
+++ openmotif-2.3.1/configure 2008-12-28 16:45:10.000000000 -0500
@@ -21974,9 +21974,9 @@
lt_save_CFLAGS="$CFLAGS"
lt_save_CPPFLAGS="$CPPFLAGS"
lt_save_LIBS="$LIBS"
-LIBS="$X_LIBS -lXt $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
-CFLAGS="$X_CFLAGS $CFLAGS"
-CPPFLAGS="$X_CFLAGS $CPPFLAGS"
+LIBS="$LIBS $X_LIBS -lXt $X_PRE_LIBS -lX11 $X_EXTRA_LIBS"
+CFLAGS="$CFLAGS $X_CFLAGS"
+CPPFLAGS="$CPPFLAGS $X_CFLAGS"
if test "$cross_compiling" = yes; then
lt_cv_xthreads=dunno
else
@@ -22351,8 +22351,8 @@

save_LIBS="$LIBS"
save_CFLAGS="$CFLAGS"
-LIBS="$X_LIBS $LIBS"
-CFLAGS="$X_CFLAGS $CFLAGS"
+LIBS="$LIBS $X_LIBS"
+CFLAGS="$CFLAGS $X_CFLAGS"

for ac_header in X11/Xmu/Editres.h
do
--- openmotif-2.3.1/tools/wml/Makefile.in.org 2009-03-26 20:36:34.000000000 -0400
+++ openmotif-2.3.1/tools/wml/Makefile.in 2009-03-26 20:37:00.000000000 -0400
@@ -54,7 +54,7 @@
ARFLAGS = cru
libwml_a_AR = $(AR) $(ARFLAGS)
libwml_a_LIBADD =
-am_libwml_a_OBJECTS = wmlparse.$(OBJEXT) wml.$(OBJEXT) \
+am_libwml_a_OBJECTS = wmlparse.$(OBJEXT) \
wmloutkey.$(OBJEXT) wmlouth.$(OBJEXT) wmloutmm.$(OBJEXT) \
wmloutp1.$(OBJEXT) wmlresolve.$(OBJEXT) wmlsynbld.$(OBJEXT) \
wmlutils.$(OBJEXT)
--- openmotif-2.3.2/clients/mwm/Makefile.in.orig 2009-03-20 09:52:20.000000000 -0400
+++ openmotif-2.3.2/clients/mwm/Makefile.in 2009-07-08 20:36:47.000000000 -0400
@@ -71,10 +71,10 @@
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(CPPFLAGS) $(AM_CFLAGS)
LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
- $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS)
CCLD = $(CC)
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
@@ -256,7 +256,7 @@
-DCDE_CONFIGURATION_TOP=\"@CDE_CONFIGURATION_TOP@\" \
-DBITMAPDIR=\"@INCDIR@/bitmaps\" \
-I$(top_builddir)/lib \
- -I$(srcdir)/../../lib ${X_CFLAGS}
+ -I$(srcdir)/../../lib ${CFLAGS} ${X_CFLAGS}

SRCS1 = WmCDInfo.c WmCDecor.c WmCEvent.c\
WmCPlace.c WmColormap.c WmError.c\
@@ -373,7 +373,7 @@
done
mwm$(EXEEXT): $(mwm_OBJECTS) $(mwm_DEPENDENCIES)
@rm -f mwm$(EXEEXT)
- $(LINK) $(mwm_OBJECTS) $(mwm_LDADD) $(LIBS)
+ $(LINK) $(mwm_OBJECTS) $(LIBS) $(mwm_LDADD)

mostlyclean-compile:
-rm -f *.$(OBJEXT)
--- openmotif-2.3.2/clients/xmbind/Makefile.in.orig 2009-03-20 09:52:21.000000000 -0400
+++ openmotif-2.3.2/clients/xmbind/Makefile.in 2009-07-08 20:38:45.000000000 -0400
@@ -57,10 +57,10 @@
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(CPPFLAGS) $(AM_CFLAGS)
LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
- $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS)
CCLD = $(CC)
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
@@ -214,7 +214,7 @@
top_srcdir = @top_srcdir@
MAINTAINERCLEANFILES = Makefile.in
LDADD = ../../lib/Xm/libXm.la
-INCLUDES = -I$(srcdir)/../../lib -I$(top_builddir)/lib ${X_CFLAGS}
+INCLUDES = -I$(srcdir)/../../lib -I$(top_builddir)/lib ${CFLAGS} ${X_CFLAGS}
all: all-am

.SUFFIXES:
--- openmotif-2.3.2/lib/Xm/DragBS.c.org 2009-08-29 10:27:40.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/DragBS.c 2009-08-29 10:31:34.000000000 -0400
@@ -217,9 +217,9 @@
static unsigned long firstProtectRequest;
static Window errorWindow;

-static XContext displayToMotifWindowContext = (XContext) NULL;
-static XContext displayToTargetsContext = (XContext) NULL;
-static XContext displayToAtomsContext = (XContext) NULL;
+static XContext displayToMotifWindowContext = (XContext)(uintptr_t) NULL;
+static XContext displayToTargetsContext = (XContext)(uintptr_t) NULL;
+static XContext displayToAtomsContext = (XContext)(uintptr_t) NULL;


/*****************************************************************************
@@ -304,7 +304,7 @@
XContext loc_context;

_XmProcessLock();
- if (displayToMotifWindowContext == (XContext) NULL) {
+ if (displayToMotifWindowContext == (XContext)(uintptr_t) NULL) {
displayToMotifWindowContext = XUniqueContext();
}
loc_context = displayToMotifWindowContext;
@@ -335,7 +335,7 @@
XContext loc_context;

_XmProcessLock();
- if (displayToMotifWindowContext == (XContext) NULL) {
+ if (displayToMotifWindowContext == (XContext)(uintptr_t) NULL) {
displayToMotifWindowContext = XUniqueContext();
}
loc_context = displayToMotifWindowContext;
@@ -378,7 +378,7 @@
XContext loc_context;

_XmProcessLock();
- if (displayToTargetsContext == (XContext) NULL) {
+ if (displayToTargetsContext == (XContext)(uintptr_t) NULL) {
displayToTargetsContext = XUniqueContext();
}
loc_context = displayToTargetsContext;
@@ -409,7 +409,7 @@
XContext loc_context;

_XmProcessLock();
- if (displayToTargetsContext == (XContext) NULL) {
+ if (displayToTargetsContext == (XContext)(uintptr_t) NULL) {
displayToTargetsContext = XUniqueContext();
}
loc_context = displayToTargetsContext;
@@ -464,7 +464,7 @@
XContext loc_context;

_XmProcessLock();
- if (displayToAtomsContext == (XContext) NULL) {
+ if (displayToAtomsContext == (XContext)(uintptr_t) NULL) {
displayToAtomsContext = XUniqueContext();
}
loc_context = displayToAtomsContext;
@@ -495,7 +495,7 @@
XContext loc_context;

_XmProcessLock();
- if (displayToAtomsContext == (XContext) NULL) {
+ if (displayToAtomsContext == (XContext)(uintptr_t) NULL) {
displayToAtomsContext = XUniqueContext();
}
loc_context = displayToAtomsContext;
--- openmotif-2.3.2/lib/Xm/DragIcon.c.org 2009-08-29 10:39:24.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/DragIcon.c 2009-08-29 10:40:12.000000000 -0400
@@ -760,7 +760,7 @@
#undef Offset
#define Offset(x) (XtOffsetOf( struct _XmDragIconRec, drag.x))

-static XContext _XmTextualDragIconContext = (XContext) NULL;
+static XContext _XmTextualDragIconContext = (XContext)(uintptr_t) NULL;

static XtResource resources[]=
{
@@ -1240,7 +1240,7 @@
use_alt = dpy -> display.enable_drag_icon;

_XmProcessLock();
- if (_XmTextualDragIconContext == (XContext) NULL)
+ if (_XmTextualDragIconContext == (XContext)(uintptr_t) NULL)
_XmTextualDragIconContext = XUniqueContext();
loc_context = _XmTextualDragIconContext;
_XmProcessUnlock();
--- openmotif-2.3.2/lib/Xm/Text.c.org 2009-08-29 10:42:10.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/Text.c 2009-08-29 10:43:15.000000000 -0400
@@ -654,14 +654,14 @@
static void
_XmCreateCutBuffers(Widget w)
{
- static XContext context = (XContext)NULL;
+ static XContext context = (XContext)(uintptr_t)NULL;
char * tmp = NULL;
Display *dpy = XtDisplay(w);
Screen *screen = XtScreen(w);
XContext local_context;

_XmProcessLock();
- if (context == (XContext)NULL) context = XUniqueContext();
+ if (context == (XContext)(uintptr_t)NULL) context = XUniqueContext();

local_context = context;
_XmProcessUnlock();
@@ -3023,7 +3023,7 @@
if (!tw->text.editable && editable) {
OutputData o_data = tw->text.output->data;

- XmImRegister(widget, (unsigned int) NULL);
+ XmImRegister(widget, (unsigned int)(uintptr_t) NULL);

(*tw->text.output->PosToXY)(tw, tw->text.cursor_position,
&xmim_point.x, &xmim_point.y);
--- openmotif-2.3.2/lib/Xm/TextF.c.org 2009-08-29 10:46:06.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/TextF.c 2009-08-29 10:47:10.000000000 -0400
@@ -7306,7 +7306,7 @@
XmTextFieldSetEditable((Widget)tf, TextF_Editable(tf));

if (TextF_Editable(tf)) {
- XmImRegister((Widget)tf, (unsigned int) NULL);
+ XmImRegister((Widget)tf, (unsigned int)(uintptr_t) NULL);
GetXYFromPos(tf, TextF_CursorPosition(tf), &xmim_point.x, &xmim_point.y);
(void)TextFieldGetDisplayRect((Widget)tf, &xmim_area);
n = 0;
@@ -8178,7 +8178,7 @@
diff_values = True;
if (TextF_WcValue(new_tf) == NULL) {
TextF_WcValue(new_tf) = (wchar_t*) XtMalloc(sizeof(wchar_t));
- *TextF_WcValue(new_tf) = (wchar_t)NULL;
+ *TextF_WcValue(new_tf) = (wchar_t)(uintptr_t)NULL;
}
ValidateString(new_tf, (char*)TextF_WcValue(new_tf), True);
} else if (TextF_Value(new_tf) != TextF_Value(old_tf)) {
@@ -10091,7 +10091,7 @@
* give the IM the relevent values. */

if (!TextF_Editable(tf) && editable) {
- XmImRegister((Widget)tf, (unsigned int) NULL);
+ XmImRegister((Widget)tf, (unsigned int)(uintptr_t) NULL);

GetXYFromPos(tf, TextF_CursorPosition(tf), &xmim_point.x,
&xmim_point.y);
--- openmotif-2.3.2/lib/Xm/Protocols.c.org 2009-08-29 10:48:46.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/Protocols.c 2009-08-29 10:49:20.000000000 -0400
@@ -136,7 +136,7 @@
*
***************************************************************************/

-static XContext allProtocolsMgrContext = (XContext) NULL;
+static XContext allProtocolsMgrContext = (XContext)(uintptr_t) NULL;


#define Offset(field) XtOffsetOf( struct _XmProtocolRec, protocol.field)
@@ -374,7 +374,7 @@
display = XtDisplay(shell);

_XmProcessLock();
- if (allProtocolsMgrContext == (XContext) NULL)
+ if (allProtocolsMgrContext == (XContext)(uintptr_t) NULL)
allProtocolsMgrContext = XUniqueContext();
_XmProcessUnlock();

--- openmotif-2.3.2/lib/Xm/VendorS.c.org 2009-08-29 10:50:33.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/VendorS.c 2009-08-29 10:51:00.000000000 -0400
@@ -1576,8 +1576,8 @@
ttp->post_delay = 5000;
ttp->post_duration = 5000;
ttp->enable = False;
- ttp->timer = (int) NULL;
- ttp->duration_timer = (int) NULL;
+ ttp->timer = (int)(uintptr_t) NULL;
+ ttp->duration_timer = (int)(uintptr_t) NULL;
ttp->leave_time = 0;
ttp->slider = ttp->label = NULL;

--- openmotif-2.3.2/lib/Xm/Synthetic.c.org 2009-08-29 10:52:02.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/Synthetic.c 2009-08-29 10:54:51.000000000 -0400
@@ -197,7 +197,7 @@

for (i = 0; i < num_resources; i++)
resources[i].resource_name =
- (String) XrmPermStringToQuark (resources[i].resource_name);
+ (String)(uintptr_t) XrmPermStringToQuark (resources[i].resource_name);
}

/**********************************************************************
@@ -241,7 +241,7 @@
for (j = 0; j < num_resources; j++)
{
if ((resources[j].export_proc) &&
- (XrmQuark)(resources[j].resource_name) == quark)
+ (XrmQuark)(uintptr_t)(resources[j].resource_name) == quark)
{
value_size = resources[j].resource_size;

@@ -512,7 +512,7 @@
for (j = 0; j < num_resources; j++)
{
if ((resources[j].import_proc) &&
- (XrmQuark)(resources[j].resource_name) == quark)
+ (XrmQuark)(uintptr_t)(resources[j].resource_name) == quark)
{
value = args[i].value;

--- openmotif-2.3.2/lib/Xm/Obso2_0.c.org 2009-08-29 10:56:29.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/Obso2_0.c 2009-08-29 10:57:39.000000000 -0400
@@ -1584,7 +1584,7 @@
Stuff from Desktop.c
**********************/

-static XContext actualClassContext = (XContext) NULL;
+static XContext actualClassContext = (XContext)(uintptr_t) NULL;


/*ARGSUSED*/
@@ -1611,7 +1611,7 @@
{
WidgetClass actualClass;

- if (actualClassContext == (XContext) NULL)
+ if (actualClassContext == (XContext)(uintptr_t) NULL)
actualClassContext = XUniqueContext();

/*
@@ -1645,7 +1645,7 @@
WidgetClass previous;
WidgetClass oldActualClass;

- if (actualClassContext == (XContext) NULL)
+ if (actualClassContext == (XContext)(uintptr_t) NULL)
actualClassContext = XUniqueContext();

/*
@@ -1692,7 +1692,7 @@
Cardinal *num_args )
{
XmDesktopObject worldObject;
- static XContext worldObjectContext = (XContext) NULL;
+ static XContext worldObjectContext = (XContext)(uintptr_t) NULL;
XmWidgetExtData ext;
Display *display;

@@ -1701,7 +1701,7 @@
** the display is closed, so that we don't get bad data if a second
** display with the same id is opened.
*/
- if (worldObjectContext == (XContext) NULL)
+ if (worldObjectContext == (XContext)(uintptr_t) NULL)
worldObjectContext = XUniqueContext();

display = XtDisplayOfObject(shell);
--- openmotif-2.3.2/lib/Xm/Xpmparse.c.org 2009-08-29 10:58:47.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/Xpmparse.c 2009-08-29 11:28:56.000000000 -0400
@@ -387,7 +387,7 @@
*/
if (USE_HASHTABLE) {
ErrorStatus =
- xpmHashIntern(hashtable, color->string, HashAtomData(a));
+ xpmHashIntern(hashtable, color->string, HashAtomData((uintptr_t)a));
if (ErrorStatus != XpmSuccess) {
xpmFreeColorTable(colorTable, ncolors);
return (ErrorStatus);
@@ -475,7 +475,7 @@
*/
if (USE_HASHTABLE) {
ErrorStatus =
- xpmHashIntern(hashtable, color->string, HashAtomData(a));
+ xpmHashIntern(hashtable, color->string, HashAtomData((uintptr_t)a));
if (ErrorStatus != XpmSuccess) {
xpmFreeColorTable(colorTable, ncolors);
return (ErrorStatus);
--- openmotif-2.3.2/lib/Xm/SlideC.c.org 2009-08-29 11:52:10.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/SlideC.c 2009-08-29 11:52:48.000000000 -0400
@@ -94,14 +94,14 @@
/* notify that initialize called XtArgsProc */ NULL,
/* NULL XtProc */ NULL,
/* NULL XtPointer */ NULL,
-/* NULL Cardinal */ (Cardinal)NULL,
+/* NULL Cardinal */ (Cardinal)(uintptr_t)NULL,
/* resources for subclass fields XtResourceList */ resources,
/* number of entries in resources Cardinal */ XtNumber(resources),
/* resource class quarkified XrmClass */ NULLQUARK,
-/* NULL Boolean */ (Boolean)NULL,
-/* NULL XtEnum */ (XtEnum)NULL,
-/* NULL Boolean */ (Boolean)NULL,
-/* NULL Boolean */ (Boolean)NULL,
+/* NULL Boolean */ (Boolean)(uintptr_t)NULL,
+/* NULL XtEnum */ (XtEnum)(uintptr_t)NULL,
+/* NULL Boolean */ (Boolean)(uintptr_t)NULL,
+/* NULL Boolean */ (Boolean)(uintptr_t)NULL,
/* free data for subclass pointers XtWidgetProc */ destroy,
/* NULL XtProc */ NULL,
/* NULL XtProc */ NULL,
--- openmotif-2.3.2/lib/Xm/DataF.c.org 2009-08-29 11:54:23.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/DataF.c 2009-08-29 11:57:32.000000000 -0400
@@ -9121,7 +9121,7 @@
/* CR03685 */
SGI_hack_XmImRegister((Widget)tf);
#else
- XmImRegister((Widget)tf, (unsigned int) NULL);
+ XmImRegister((Widget)tf, (unsigned int)(uintptr_t) NULL);
#endif
df_GetXYFromPos(tf, XmTextF_cursor_position(tf), &xmim_point.x, &xmim_point.y);
n = 0;
@@ -10631,7 +10631,7 @@
diff_values = True;
if (XmTextF_wc_value(new_tf) == NULL) {
XmTextF_wc_value(new_tf) = (wchar_t*) XtMalloc(sizeof(wchar_t));
- *XmTextF_wc_value(new_tf) = (wchar_t)NULL;
+ *XmTextF_wc_value(new_tf) = (wchar_t)(uintptr_t)NULL;
}
df_ValidateString(new_tf, (char*)XmTextF_wc_value(new_tf), True);
} else if (XmTextF_value(new_tf) != XmTextF_value(old_tf)) {
@@ -11777,7 +11777,7 @@
/* CR03685 */
SGI_hack_XmImRegister((Widget)tf);
#else
- XmImRegister((Widget)tf, (unsigned int) NULL);
+ XmImRegister((Widget)tf, (unsigned int)(uintptr_t) NULL);
#endif
df_GetXYFromPos(tf, XmTextF_cursor_position(tf), &xmim_point.x,
&xmim_point.y);
--- openmotif-2.3.2/lib/Xm/FontS.c.org 2009-08-29 11:59:14.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/FontS.c 2009-08-29 12:04:10.000000000 -0400
@@ -2748,7 +2748,7 @@
XmStringFree(label);

XtAddCallback(button,
- XmNactivateCallback, ChangeEncoding, (XtPointer) i);
+ XmNactivateCallback, ChangeEncoding, (XtPointer)(uintptr_t) i);

if (streq(*encodings, ENCODING_STRING(fsw)))
{
@@ -2910,7 +2910,7 @@
fsw = (XmFontSelectorWidget) w;
cf = XmFontS_font_info(fsw)->current_font;

- if ((int) data == 0)
+ if ((int)(uintptr_t) data == 0)
{
XtFree(ENCODING_STRING(fsw));
ENCODING_STRING(fsw) = XtNewString(ANY_ENCODING);
@@ -2918,7 +2918,7 @@
else
{
XtFree(ENCODING_STRING(fsw));
- ENCODING_STRING(fsw) = XtNewString(ENCODING_LIST(fsw)[(int) data - 1]);
+ ENCODING_STRING(fsw) = XtNewString(ENCODING_LIST(fsw)[(int)(uintptr_t) data - 1]);
}

UpdateFamilies(fsw);
@@ -3676,7 +3676,7 @@
num_largs = 0;
XtSetArg(largs[num_largs], XmNmenuHistory, button); num_largs++;
XtSetValues(XmFontS_option_menu(set_fsw), largs, num_largs);
- ChangeEncoding((Widget) set_fsw, (XtPointer) current, NULL);
+ ChangeEncoding((Widget) set_fsw, (XtPointer)(uintptr_t) current, NULL);
}
else
{
--- openmotif-2.3.2/clients/mwm/WmResParse.c.org 2009-08-29 12:07:12.000000000 -0400
+++ openmotif-2.3.2/clients/mwm/WmResParse.c 2009-08-29 12:10:22.000000000 -0400
@@ -188,7 +188,7 @@
{"mod3", Mod3Mask},
{"mod4", Mod4Mask},
{"mod5", Mod5Mask},
- {NULL, (unsigned int)NULL},
+ {NULL, (unsigned int)(uintptr_t)NULL},
};

#define ALT_INDEX 3
@@ -351,14 +351,14 @@
{"btn5up", ButtonRelease, ParseImmed, Button5, FALSE},
{"btn5click", ButtonRelease, ParseImmed, Button5, TRUE},
{"btn5click2", ButtonPress, ParseImmed, Button5, TRUE},
- { NULL, (unsigned int)NULL, (Boolean(*)())NULL, (unsigned int)NULL, (Boolean)NULL}
+ { NULL, (unsigned int)(uintptr_t)NULL, (Boolean(*)())NULL, (unsigned int)(uintptr_t)NULL, (Boolean)(uintptr_t)NULL}
};


static EventTableEntry keyEvents[] = {

{"key", KeyPress, ParseKeySym, 0, FALSE},
- { NULL, (unsigned int)NULL, (Boolean(*)())NULL, (unsigned int)NULL, (Boolean)NULL}
+ { NULL, (unsigned int)(uintptr_t)NULL, (Boolean(*)())NULL, (unsigned int)(uintptr_t)NULL, (Boolean)(uintptr_t)NULL}
};

#ifdef PANELIST
--- openmotif-2.3.2/lib/Xm/IconG.c.org 2009-08-29 12:26:45.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/IconG.c 2009-08-29 12:27:15.000000000 -0400
@@ -279,8 +279,8 @@

/* those are created in ClassInitialize and filled by the
IconConverter. */
-static XContext largeIconContext = (XContext) NULL;
-static XContext smallIconContext = (XContext) NULL;
+static XContext largeIconContext = (XContext)(uintptr_t) NULL;
+static XContext smallIconContext = (XContext)(uintptr_t) NULL;

static XPointer dummy;
#define OwnLargeMask(widget) \
--- openmotif-2.3.2/clients/mwm/WmMenu.c.org 2009-08-29 12:45:19.000000000 -0400
+++ openmotif-2.3.2/clients/mwm/WmMenu.c 2009-08-29 12:47:09.000000000 -0400
@@ -861,8 +861,8 @@
static MenuItem *MakeClientCommandMenuItem (String label, String funcArgs)
{
return(MakeMenuItem(label, F_InvokeCommand, funcArgs,
- (KeySym) NULL, (unsigned int)0,
- (KeyCode) NULL, (String)NULL));
+ (KeySym)(uintptr_t) NULL, (unsigned int)0,
+ (KeyCode)(uintptr_t) NULL, (String)(uintptr_t)NULL));
}


@@ -2216,7 +2216,7 @@
if (newMenuSpec == (MenuSpec *) NULL)
{
newMenuSpec = MakeMenuSpec(funcarg_buf,
- tree == NULL ? (CARD32)NULL
+ tree == NULL ? (CARD32)(uintptr_t)NULL
: tree->commandID);
if (duplicate_globals) newMenuSpec->clientLocal = TRUE;
else newMenuSpec->clientLocal = FALSE;
--- openmotif-2.3.2/lib/Xm/XpmI.h.org 2009-08-29 13:19:19.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/XpmI.h 2009-08-29 13:20:13.000000000 -0400
@@ -291,7 +291,7 @@
FUNC(xpmHashIntern, int, (xpmHashTable *table, char *tag, void *data));

#define HashAtomData(i) ((void *)i)
-#define HashColorIndex(slot) ((unsigned int)((*slot)->data))
+#define HashColorIndex(slot) ((unsigned int)(uintptr_t)((*slot)->data))
#define USE_HASHTABLE (cpp > 2 && ncolors > 4)

/* I/O utility */
--- openmotif-2.3.2/lib/Xm/BaseClass.c.org 2009-08-29 13:31:43.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/BaseClass.c 2009-08-29 13:32:05.000000000 -0400
@@ -577,7 +577,7 @@
static ExtToContextRec extToContextMap[16];
Cardinal i;
ExtToContext curr;
- XContext context = (XContext) NULL;
+ XContext context = (XContext)(uintptr_t) NULL;

_XmProcessLock();
for (i = 0, curr = &extToContextMap[0];
--- openmotif-2.3.2/lib/Xm/XmIm.c.org 2009-08-29 13:33:41.000000000 -0400
+++ openmotif-2.3.2/lib/Xm/XmIm.c 2009-08-29 13:33:59.000000000 -0400
@@ -2499,7 +2499,7 @@
(void) add_ref(&xic_info->widget_refs, widget);

/* Set the current XIC for this widget. */
- if (xim_info->current_xics == (XContext) NULL)
+ if (xim_info->current_xics == (XContext)(uintptr_t) NULL)
xim_info->current_xics = XUniqueContext();
(void) XSaveContext(XtDisplay(widget), (XID) widget,
xim_info->current_xics, (XPointer) xic_info);
--- openmotif-2.3.2/lib/Xm/XmP.h 2005-11-14 09:38:28.000000000 -0500
+++ openmotif-2.3.2.patched/lib/Xm/XmP.h 2011-07-15 12:08:06.000000000 -0400
@@ -1455,12 +1455,15 @@

#endif /* NO_XM_1_2_BC */

-#if __GNUC__
+#ifdef __GNUC__
# define XM_DEPRECATED __attribute__((__deprecated__))
-# define XM_ALIAS(sym) __attribute__((__weak__,alias(#sym)))
+# ifndef __APPLE__
+# define XM_ALIAS(sym) __attribute__((__weak__,alias(#sym)))
+# else
+# define XM_ALIAS(sym)
+# endif
#else
# define XM_DEPRECATED
-# define XM_ALIAS(sym)
#endif

#endif /* _XmP_h */

openmotif4 _unstable_ port .patch