blob: 8aaef4cfccd7bee8a9e62c439717f30c7f93061f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
|
# -*- Mode: Makefile -*-
# Port of: GNU Ada gnat
# Version required: 2.03
# Space required: >= 23MB
# Date created: Sat Mar 18 02:16:45 1995
# Porter: nils@guru.ims.uni-stuttgart.de
#
DISTNAME= gnat-2.03-src
MASTER_SITES= ftp://cs.nyu.edu/pub/gnat/
CATEGORIES+= languages
EXTRACT_SUFX= .tar.gz
# You need a compiler who calls an existing gnat compiler:
CC = gcc-2.6.3
# You have to tell me where your gcc 2.6.3 source is located
COMPILERSOURCE = /usr/src/gnu/usr.bin/cc
#COMPILERSOURCE = /cdrom/filesys/usr/src/gnu/usr.bin/cc
# Which version of gcc do we have? Must be either 2.6.2 or 2.6.3.
CCVERSION= 2.6.3
USE_GMAKE= true
# This is for the package: target. I decided to install the Ada compiler
# as /usr/libexec/gnat1, the rest in /usr/local/{bin,adainclude,adalib}.
PREFIX = /usr
WRKDIR = ${.CURDIR}/work
CONFIGURE_COOKIE= ${WRKDIR}/.configure_done
PREBUILD_COOKIE = ${WRKDIR}/.prebuild_done
BUILD_COOKIE = ${WRKDIR}/.build_done
INSTALL_COOKIE = ${WRKDIR}/.install_done
pre-build: ${PREBUILD_COOKIE}
${PREBUILD_COOKIE}:
@echo "===> Building patched gcc library for ${DISTNAME}"
cd ${WRKSRC}/gcc && \
${MAKE} CC="${CC} -I. -I${COMPILERSOURCE}/include" \
COMPILERSOURCE="${COMPILERSOURCE}"
@${TOUCH} ${TOUCHFLAGS} ${PREBUILD_COOKIE}
build: configure pre-build ${BUILD_COOKIE}
${BUILD_COOKIE}:
@echo "===> Building for ${DISTNAME}"
cd ${WRKSRC}/ada; \
${GMAKE} CC="${CC}" COMPILERSOURCE="${COMPILERSOURCE}"
@${TOUCH} ${TOUCH_FLAGS} ${BUILD_COOKIE}
configure: extract patch ${CONFIGURE_COOKIE}
${CONFIGURE_COOKIE}:
@echo "===> Configuring for ${DISTNAME}"
@env CURDIR=${.CURDIR} DISTDIR=${DISTDIR} WRKDIR=${WRKDIR} \
WRKSRC=${WRKSRC} PATCHDIR=${PATCHDIR} SCRIPTDIR=${SCRIPTDIR} \
FILESDIR=${FILESDIR} PORTSDIR=${PORTSDIR} PREFIX=${PREFIX} \
DEPENDS="${DEPENDS}" \
COMPILERSOURCE="${COMPILERSOURCE}" CCVERSION="${CCVERSION}" \
${SHELL} ${SCRIPTDIR}/configure;
@${TOUCH} ${TOUCH_FLAGS} ${CONFIGURE_COOKIE}
install: build ${INSTALL_COOKIE}
${INSTALL_COOKIE}:
@echo "===> Installing for ${DISTNAME}"
@${MAKE} ${.MAKEFLAGS} pre-install
@(cd ${WRKSRC}/ada; \
${MAKE} PREFIX_DIR=${PREFIX} ${MAKE_FLAGS} ${MAKEFILE} \
${INSTALL_TARGET})
@${TOUCH} ${TOUCH_FLAGS} ${INSTALL_COOKIE}
.include <bsd.port.mk>
|