aboutsummaryrefslogtreecommitdiffstats
path: root/lang/gnustep-base/Makefile
blob: 9e0f831fb0aebf6cf9efd2cff20be91601ad5bd8 (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
72
73
74
75
76
# New ports collection makefile for:    gnustep-base
# Date created:         17 April 2001
# Whom:                 Thomas Gellekum <tg@FreeBSD.org>
#
# $FreeBSD$
#

PORTNAME=   gnustep-base
PORTVERSION=    1.1.0
CATEGORIES= lang devel
MASTER_SITES=   ftp://ftp.gnustep.org/pub/gnustep/core/ \
        http://ftp.codefactory.se/pub/gnu/gstep/ \
        http://planetmirror.com/pub/gnustep/core/

MAINTAINER= ports@FreeBSD.org

BUILD_DEPENDS=  ${SYSLIBDIR}/${GNU_ARCH}/${OPSYS:L}/libobjc.so:${PORTSDIR}/lang/gnustep-objc
LIB_DEPENDS=    xml2.5:${PORTSDIR}/textproc/libxml2
RUN_DEPENDS=    ${SYSLIBDIR}/${GNU_ARCH}/${OPSYS:L}/libobjc.so:${PORTSDIR}/lang/gnustep-objc

.include <bsd.port.pre.mk>

.if ${OSVERSION} < 300000
BROKEN=     "Sorry, this port does not work on FreeBSD-2.2.x"
.endif

PREFIX=     ${LOCALBASE}/GNUstep
USE_AUTOCONF=   yes
USE_NEWGCC= yes
GNU_CONFIGURE=  yes
CONFIGURE_ARGS= --disable-procfs
CONFIGURE_TARGET=
USE_GMAKE=  yes
MAKEFILE=
MAKE_FLAGS= OPTFLAG="${CFLAGS}"
NO_MTREE=   yes

.if ${MACHINE_ARCH} == "i386"
GNU_ARCH=   ix86
.else
GNU_ARCH=   ${MACHINE_ARCH}
.endif
PLIST_SUB+= GNU_ARCH=${GNU_ARCH} OPSYS=${OPSYS:L} VERSION=${PORTVERSION} \
        MAJORVERSION=${PORTVERSION:C/([0-9]).*/\1/1}
ETCDIR=     ${PREFIX}/../etc
SYSLIBDIR=  ${PREFIX}/System/Libraries

do-configure:
    @(cd ${WRKSRC}; . ${PREFIX}/System/Makefiles/GNUstep.sh; \
        if ! ${SETENV} CC="${CC}" CXX="${CXX}" \
        CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}" \
        INSTALL="/usr/bin/install -c -o ${BINOWN} -g ${BINGRP}" \
        INSTALL_DATA="${INSTALL} -c" \
        INSTALL_PROGRAM="${INSTALL} -c" \
        INSTALL_SCRIPT="${INSTALL_SCRIPT}" \
        ${CONFIGURE_ENV} ./${CONFIGURE_SCRIPT} ${CONFIGURE_ARGS}; then \
            ${ECHO} "===>  Script \"${CONFIGURE_SCRIPT}\" failed: here are the contents of \"${CONFIGURE_LOG}\""; \
            ${CAT} ${CONFIGURE_LOG}; \
            ${ECHO} "(end of \"${CONFIGURE_LOG}\")"; \
            ${FALSE}; \
        fi)

do-build:
    @(cd ${WRKSRC}; . ${PREFIX}/System/Makefiles/GNUstep.sh; \
        ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${ALL_TARGET})

do-install:
    @(cd ${WRKSRC}; . ${PREFIX}/System/Makefiles/GNUstep.sh; \
        ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${INSTALL_TARGET})

post-install:
    @${MKDIR} ${ETCDIR}
    ${INSTALL_SCRIPT} ${FILESDIR}/GNUstep.sh ${ETCDIR}/rc.d
    ${INSTALL_DATA} ${FILESDIR}/gdomap_if ${ETCDIR}

.include <bsd.port.post.mk>