Package-Name: lesstif
Gentoo-Package: x11-libs/lesstif
Homepage: http://www.lesstif.org/
Source: sourceforge:///lesstif/lesstif-(\d+.\d+.\d+).tar.gz $1
Zap-Before-Install: 1
Repack:
	tar xzvfp "$(SOURCE)"
Compile:
	chmod a-x COPYING*
	cp -p AUTHORS BUG-REPORTING COPYING* CREDITS ChangeLog FAQ NEWS README ReleaseNotes* "$(PREFIX)/"
	$(MAKE) -f ../Makefile configure CONFIGURE_OPTS=--enable-static
	$(MAKE)
# Avoid problems with overwriting shared libraries
	rm -f "$(PREFIX)"/lib/*.so*
	$(MAKE) install
	rm -f "$(PREFIX)"/LessTif/[A-Z]*
	rm -rf "$(PREFIX)"/doc
	mv "$(PREFIX)"/LessTif/doc "$(PREFIX)"/
	rmdir "$(PREFIX)"/LessTif
Install:
	$(MAKE) instbin BIN="mwm mxmkmf uil xmbind"
	$(MAKE) instlib LIB="DtPrint Mrm Uil Xm"
	$(MAKE) addldso
	$(MAKE) instinc INC="Dt Mrm Xm uil"
	$(MAKE) instman SECTION=1 MAN="lesstif ltversion mwm uil xmbind"
	$(MAKE) instman SECTION=3 MAN="ApplicationShell Composite Constraint Core LessTifInternals Object OverrideShell Rect Shell TopLevelShell TransientShell UnNamedObj VendorShell WmShell Xm*"
	$(MAKE) instman SECTION=5 MAN="VirtualBindings mwmrc"
	$(MAKE) instaclocal M4=ac_find_motif
	if [ -d /usr/X11/lib/X11/app-defaults ] ; then \
		ln -fs "$(PREFIX)"/lib/X11/app-defaults/Mwm /usr/X11/lib/X11/app-defaults ; \
	fi
Clean:
	@set -e ; cd "$(PREFIX)"/lib ; \
	for lib in *.so.[0-9] ; do \
		reallib=`/bin/ls -l "$$lib" | sed 's/.* -> //'` ; \
		for file in $$lib.[0-9]*.[0-9]* ; do \
			if test "$$file" != "$$reallib" ; then \
				rm -fv "$$file" ; \
			fi ; \
		done ; \
	done
Patch: <<EOT
######## begin Xorg C++ prototype conflict patch
--- include/Motif-2.1/Xm/VendorSP.h.old	2004-08-29 04:23:27 +0900
+++ include/Motif-2.1/Xm/VendorSP.h	2007-04-21 03:24:55 +0900
@@ -28,12 +28,13 @@
 
 #include <Xm/XmP.h>
 #include <Xm/VendorS.h>
-#include <X11/ShellP.h>
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
+#include <X11/ShellP.h>
+
 XMLIBEXPORT extern Cardinal _XmFilterResources(XtResource *resources,
 				   Cardinal numResources,
 				   WidgetClass filterClass,
######## end Xorg C++ prototype conflict patch
--- scripts/autoconf/Makefile.am.old	1999-09-12 20:13:53 +0900
+++ scripts/autoconf/Makefile.am	2004-10-15 12:09:19 +0900
@@ -5,7 +5,7 @@
 
 EXTRA_DIST=	ac_find_motif.m4
 
-aclocaldir = @ACLOCALDIR@
+aclocaldir = $(datadir)/aclocal
 
 if Aclocal
 
--- scripts/autoconf/Makefile.in.old	2004-09-29 06:37:55 +0900
+++ scripts/autoconf/Makefile.in	2004-10-15 12:32:52 +0900
@@ -246,7 +246,7 @@
 #
 MAINTAINERCLEANFILES = Makefile.in
 EXTRA_DIST = ac_find_motif.m4
-aclocaldir = @ACLOCALDIR@
+aclocaldir = $(datadir)/aclocal
 @Aclocal_TRUE@aclocal_DATA = ac_find_motif.m4
 all: all-am
 
EOT

/pkg/lesstif/
/usr/X11/lib/X11/app-defaults/Mwm
/usr/bin/mwm
/usr/bin/mxmkmf
/usr/bin/uil
/usr/bin/xmbind
/usr/include/Dt
/usr/include/Mrm
/usr/include/Xm
/usr/include/uil
/usr/lib/libDtPrint.*
/usr/lib/libMrm.*
/usr/lib/libUil.*
/usr/lib/libXm.*
/usr/man/man1/lesstif.1.gz
/usr/man/man1/ltversion.1.gz
/usr/man/man1/mwm.1.gz
/usr/man/man1/uil.1.gz
/usr/man/man1/xmbind.1.gz
/usr/man/man3/ApplicationShell.3.gz
/usr/man/man3/Composite.3.gz
/usr/man/man3/Constraint.3.gz
/usr/man/man3/Core.3.gz
/usr/man/man3/LessTifInternals.3.gz
/usr/man/man3/Object.3.gz
/usr/man/man3/OverrideShell.3.gz
/usr/man/man3/Rect.3.gz
/usr/man/man3/Shell.3.gz
/usr/man/man3/TopLevelShell.3.gz
/usr/man/man3/TransientShell.3.gz
/usr/man/man3/UnNamedObj.3.gz
/usr/man/man3/VendorShell.3.gz
/usr/man/man3/WmShell.3.gz
/usr/man/man3/Xm*.3.gz
/usr/man/man5/VirtualBindings.5.gz
/usr/man/man5/mwmrc.5.gz
/usr/share/aclocal/ac_find_motif.m4
