Commits

Anonymous committed da2dbec

Fix package build so XEmacs 21.5 doesn't barf on Mule-UCS

Comments (0)

Files changed (2)

+2003-04-04  Steve Youngs  <youngs@xemacs.org>
+
+	* Makefile (REQ_MIN_VERSION): New.
+	(CHECK_VERSION): New.
+	(bad-version): New.
+	So this package can be "made" with XEmacs 21.1.
+
 2003-03-30  Steve Youngs  <youngs@xemacs.org>
 
 	* Makefile (EARLY_GENERATED_LISP): Revert previous change.
 REQUIRES = mule-base
 CATEGORY = mule
 
+# Mule-UCS is a unique package in that it does not compile or run
+# under XEmacsen 21.1, at least not "out of the box".  So here's
+# some really ugly Makefile voodoo that will allow people using XEmacs
+# 21.1 to build the packages without it blowing up in their faces.
+# Don't try this at home, kids.  SY.
+REQ_MIN_VERSION = 21 4
+include ../../Local.rules
+CHECK_VERSION =	$(XEMACS) -batch -eval '(princ (emacs-version>= $(value REQ_MIN_VERSION)))'
+
+ifeq ($(shell $(CHECK_VERSION)),t)
 EXTRA_SOURCES = \
 	lisp/ChangeLog \
 	lisp/un-trbase.el
 #compile::
 #	$(XEMACS) -no-autoloads -batch -l mucs-comp.el
 
+else
+include ../../Version.rules
+
+bad-version:
+	@echo "************************ W A R N I N G *************************"
+	@echo "Building Mule-UCS with versions less than 21.4 is unsupported by"
+	@echo "the XEmacs Project."
+	@echo "If you need this feature, contact the package maintainer directly:"
+	@echo "$(MAINTAINER)"
+endif
+