1996-03-20 22:10:19 +00:00
|
|
|
# New ports collection makefile for: modula-3
|
1996-09-27 02:26:41 +00:00
|
|
|
# Version required: 3.6
|
1996-03-20 22:10:19 +00:00
|
|
|
# Date created: 18 Mar 1996
|
|
|
|
# Whom: John Polstra <jdp@polstra.com>
|
|
|
|
#
|
1998-04-28 22:23:18 +00:00
|
|
|
# $Id: Makefile,v 1.18 1997/07/26 00:24:53 jdp Exp $
|
1996-03-20 22:10:19 +00:00
|
|
|
#
|
|
|
|
|
1996-09-27 02:26:41 +00:00
|
|
|
DISTNAME= modula-3-3.6
|
1996-11-12 02:19:40 +00:00
|
|
|
CATEGORIES= lang
|
1996-10-29 23:17:19 +00:00
|
|
|
DISTFILES=
|
1996-03-20 22:10:19 +00:00
|
|
|
|
|
|
|
MAINTAINER= jdp@polstra.com
|
|
|
|
|
1996-10-29 23:17:19 +00:00
|
|
|
DEPENDS= ${PORTSDIR}/lang/modula-3-lib
|
Update the Modula-3 port with two main goals in mind.
First, change the port so that it builds a much smaller subset of
the SRC distribution. This eliminates the enormous swap space
requirements of the earlier port, greatly reduces the footprint of
the installed tree, and cuts the size of the package in half.
Second, include many important new patches. Among them is a slightly
modified version of phkmalloc that is thread-safe for Modula-3.
It eradicates some rare and baffling core dumps that cropped up
from time to time in the previous version of the port. The Modula-3
runtime itself is careful to use mutual exclusion around calls to
malloc. But there remained some sneaky backdoor paths into it from
external libraries.
Confession: In the original version of the Modula-3 port, I used
a major version number of 353 for the shared libraries, to correspond
with the SRC version number 3.5.3. That was a dumb move -- I should
have used 1. The current update is incompatible at the shared
library level, requiring me to increment the major version number
to 354, even though this is still based on SRC release 3.5.3. This
is bound to confuse some folks, unfortunately. I weighed a number
of alternatives, such as (a) cheating and going back to 1, and (b)
using a 4-digit major version such as 3531. But in the end I
decided that 354 would be the best solution, even though it's
confusing.
1996-09-10 05:25:10 +00:00
|
|
|
|
1996-10-29 23:17:19 +00:00
|
|
|
WRKSRC= ${PORTSDIR}/lang/modula-3-lib/work
|
1996-12-30 23:28:13 +00:00
|
|
|
NO_CHECKSUM= yes
|
1996-10-29 23:17:19 +00:00
|
|
|
NO_CONFIGURE= yes
|
|
|
|
NO_BUILD= yes
|
1997-07-26 00:24:53 +00:00
|
|
|
MAN1= analyze_coverage.1 formsedit.1 m3browser.1 \
|
|
|
|
m3build.1 m3bundle.1 m3pp.1 m3ship.1 m3tohtml.1 \
|
|
|
|
m3totex.1 m3where.1 quake.1 recordheap.1 \
|
|
|
|
replayheap.1 showheap.1 shownew.1 showthread.1
|
1996-03-20 22:10:19 +00:00
|
|
|
|
1996-11-01 20:27:23 +00:00
|
|
|
# Keep these in sync with the PLIST and with the library version numbers
|
1998-04-28 22:23:18 +00:00
|
|
|
# in the modula-3-lib port (PLIST and patch-ah there).
|
|
|
|
major= 6
|
1997-07-11 05:16:45 +00:00
|
|
|
minor= 0
|
1996-11-01 20:27:23 +00:00
|
|
|
|
1996-03-20 22:10:19 +00:00
|
|
|
# The Modula-3 build process insists on installing each individual
|
|
|
|
# component immediately after that component is built. To avoid having
|
|
|
|
# to do the entire build as root, we arrange for everything to first
|
|
|
|
# be "installed" into the following directory, which we own.
|
1996-10-29 23:17:19 +00:00
|
|
|
temp_prefix= ${WRKSRC}/installed
|
1996-03-20 22:10:19 +00:00
|
|
|
|
|
|
|
do-install:
|
1996-09-27 02:26:41 +00:00
|
|
|
@echo "Deleting extraneous cruft"
|
|
|
|
@cd ${temp_prefix}/lib/m3/pkg; \
|
|
|
|
rm -rf m3 m3front m3middle m3linker
|
|
|
|
@cd ${temp_prefix}/lib/m3/FreeBSD2; \
|
|
|
|
rm -f libm3front.so.*.* libm3link.so.*.* libm3middle.so.*.*
|
1996-10-29 23:17:19 +00:00
|
|
|
@echo "Installing files in \"${PREFIX}\""
|
|
|
|
@cd ${temp_prefix}; \
|
|
|
|
umask 022; \
|
1997-03-28 04:38:47 +00:00
|
|
|
sed -e "/^@/d" -e "/m3build-/d" -e "s/\.gz$$//" \
|
|
|
|
-e "/^share/d" ${PKGDIR}/PLIST | \
|
1996-10-29 23:17:19 +00:00
|
|
|
cpio -dump -R ${BINOWN}.${BINGRP} ${PREFIX}
|
1996-03-20 22:10:19 +00:00
|
|
|
@echo "Fixing absolute pathnames in installed files"
|
1997-07-13 18:49:31 +00:00
|
|
|
@${SH} ${SCRIPTDIR}/fix_pathnames ${temp_prefix} ${PREFIX}
|
1996-03-20 22:10:19 +00:00
|
|
|
@echo "Rebuilding and shipping m3build with correct pathnames"
|
|
|
|
@cd ${WRKSRC}/m3/m3build; \
|
|
|
|
LD_LIBRARY_PATH=${PREFIX}/lib/m3/FreeBSD2:$$LD_LIBRARY_PATH; \
|
|
|
|
PATH=${PREFIX}/bin:$$PATH; \
|
1996-09-27 02:26:41 +00:00
|
|
|
export LD_LIBRARY_PATH PATH; \
|
Update the Modula-3 port with two main goals in mind.
First, change the port so that it builds a much smaller subset of
the SRC distribution. This eliminates the enormous swap space
requirements of the earlier port, greatly reduces the footprint of
the installed tree, and cuts the size of the package in half.
Second, include many important new patches. Among them is a slightly
modified version of phkmalloc that is thread-safe for Modula-3.
It eradicates some rare and baffling core dumps that cropped up
from time to time in the previous version of the port. The Modula-3
runtime itself is careful to use mutual exclusion around calls to
malloc. But there remained some sneaky backdoor paths into it from
external libraries.
Confession: In the original version of the Modula-3 port, I used
a major version number of 353 for the shared libraries, to correspond
with the SRC version number 3.5.3. That was a dumb move -- I should
have used 1. The current update is incompatible at the shared
library level, requiring me to increment the major version number
to 354, even though this is still based on SRC release 3.5.3. This
is bound to confuse some folks, unfortunately. I weighed a number
of alternatives, such as (a) cheating and going back to 1, and (b)
using a 4-digit major version such as 3531. But in the end I
decided that 354 would be the best solution, even though it's
confusing.
1996-09-10 05:25:10 +00:00
|
|
|
umask 022; \
|
1996-09-27 02:26:41 +00:00
|
|
|
rm -rf FreeBSD2; \
|
1996-11-12 02:19:40 +00:00
|
|
|
${MKDIR} FreeBSD2; \
|
1996-09-27 02:26:41 +00:00
|
|
|
cd FreeBSD2; \
|
|
|
|
quake -D_bootstrap -D_all -DPACKAGE_DIR=${WRKSRC}/m3/m3build \
|
|
|
|
-DPACKAGE=m3build -DBUILD_DIR=FreeBSD2 \
|
|
|
|
${PREFIX}/lib/m3/pkg/m3build/templates/FreeBSD2 \
|
|
|
|
${WRKSRC}/m3/m3build/src/m3makefile; \
|
|
|
|
./m3ship
|
1996-10-29 23:17:19 +00:00
|
|
|
@echo "Rebuilding and shipping m3configvars with correct pathnames"
|
|
|
|
@cd ${WRKSRC}/m3/m3configvars; \
|
1996-03-20 22:10:19 +00:00
|
|
|
LD_LIBRARY_PATH=${PREFIX}/lib/m3/FreeBSD2:$$LD_LIBRARY_PATH; \
|
|
|
|
export LD_LIBRARY_PATH; \
|
|
|
|
PATH=${PREFIX}/bin:$$PATH; \
|
|
|
|
export PATH; \
|
Update the Modula-3 port with two main goals in mind.
First, change the port so that it builds a much smaller subset of
the SRC distribution. This eliminates the enormous swap space
requirements of the earlier port, greatly reduces the footprint of
the installed tree, and cuts the size of the package in half.
Second, include many important new patches. Among them is a slightly
modified version of phkmalloc that is thread-safe for Modula-3.
It eradicates some rare and baffling core dumps that cropped up
from time to time in the previous version of the port. The Modula-3
runtime itself is careful to use mutual exclusion around calls to
malloc. But there remained some sneaky backdoor paths into it from
external libraries.
Confession: In the original version of the Modula-3 port, I used
a major version number of 353 for the shared libraries, to correspond
with the SRC version number 3.5.3. That was a dumb move -- I should
have used 1. The current update is incompatible at the shared
library level, requiring me to increment the major version number
to 354, even though this is still based on SRC release 3.5.3. This
is bound to confuse some folks, unfortunately. I weighed a number
of alternatives, such as (a) cheating and going back to 1, and (b)
using a 4-digit major version such as 3531. But in the end I
decided that 354 would be the best solution, even though it's
confusing.
1996-09-10 05:25:10 +00:00
|
|
|
umask 022; \
|
1996-09-27 02:26:41 +00:00
|
|
|
rm -rf FreeBSD2; \
|
1996-03-20 22:10:19 +00:00
|
|
|
m3build; \
|
1996-10-29 23:17:19 +00:00
|
|
|
m3ship
|
1997-03-28 04:38:47 +00:00
|
|
|
@echo "Installing copyright notice"
|
|
|
|
@if [ ! -d ${PREFIX}/share/modula-3 ]; then \
|
|
|
|
${MKDIR} ${PREFIX}/share/modula-3; \
|
|
|
|
chmod 755 ${PREFIX}/share/modula-3; \
|
|
|
|
fi
|
|
|
|
@${INSTALL_DATA} ${WRKSRC}/m3/src/COPYRIGHT ${PREFIX}/share/modula-3
|
1996-03-20 22:10:19 +00:00
|
|
|
@echo "Stripping executables"
|
1996-09-27 02:26:41 +00:00
|
|
|
@cd ${temp_prefix}; \
|
|
|
|
find bin -type f ! -name recordheap | (cd ${PREFIX}; xargs strip)
|
|
|
|
@cd ${PREFIX}/lib/m3/FreeBSD2; strip m3 m3cgc1 m3mkdir
|
1996-11-01 20:27:23 +00:00
|
|
|
@cd ${PREFIX}/bin; \
|
|
|
|
ln -f m3build m3build-${major}; \
|
|
|
|
ln -f m3build m3build-${major}.${minor}
|
1996-10-29 23:17:19 +00:00
|
|
|
@echo "Fixing file permissions"
|
|
|
|
@cd ${PREFIX}; \
|
1997-07-26 00:24:53 +00:00
|
|
|
sed -e "/^@/d" -e "s/\.gz$$//" ${PKGDIR}/PLIST |\
|
|
|
|
xargs chown ${BINOWN}.${BINGRP}; \
|
|
|
|
sed -e "/^@/d" -e "s/\.gz$$//" ${PKGDIR}/PLIST |\
|
|
|
|
xargs chmod go=u-w; \
|
1996-10-29 23:17:19 +00:00
|
|
|
find -X lib/m3 -type d | xargs chown ${BINOWN}.${BINGRP}; \
|
|
|
|
find -X lib/m3 -type d | xargs chmod 755
|
1996-03-20 22:10:19 +00:00
|
|
|
@echo "Running ldconfig"
|
1997-07-17 15:13:02 +00:00
|
|
|
@${LDCONFIG} -m ${PREFIX}/lib/m3/FreeBSD2
|
1996-03-20 22:10:19 +00:00
|
|
|
|
|
|
|
.include <bsd.port.mk>
|