aboutsummaryrefslogtreecommitdiffstats
path: root/math/sedumi/Makefile
blob: e160d7c4f57a262eaced523bba8364b409af4ef4 (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
# New ports collection makefile for:    sedumi
# Date created:     2008/10/6
# Whom:         NAKATA, Maho <maho@FreeBSD.org>
#
# $FreeBSD$
#

PORTNAME=   sedumi
PORTVERSION=    1.1
PORTREVISION=   3
CATEGORIES= math
MASTER_SITES=   ${MASTER_SITE_LOCAL:S|%SUBDIR%|maho/sedumi|}
# http://sedumi.mcmaster.ca/
DISTNAME=   SeDuMi_1_1R3

MAINTAINER= maho@FreeBSD.org
COMMENT=    SeDuMi is an semidefinite programming solver on Matlab

RUN_DEPENDS=    octave:${PORTSDIR}/math/octave
BUILD_DEPENDS=  octave:${PORTSDIR}/math/octave

USE_ZIP=    yes
WRKSRC=     ${WRKDIR}/SeDuMi_1_1

pre-patch:
    @${LS} ${WRKSRC}/*.m ${WRKSRC}/*.c > ${WRKDIR}/FILELIST
    @for i in `${CAT} ${WRKDIR}/FILELIST`; do \
        cd ${WRKSRC} ; ${REINPLACE_CMD} -e 's#
##g' $$i ; \
    done
    @cd ${WRKSRC} ; ${RM} *.bak

pre-build:
    @cd ${WRKSRC} ; ${RM} *.dll *.orig

do-build:
    cd ${WRKSRC} ; octave install_sedumi.m
    @cd ${WRKSRC} ; ${RM} *.c *.o

do-install:
    ${MKDIR} ${PREFIX}/sedumi
    ${INSTALL_PROGRAM} ${WRKSRC}/*mex ${PREFIX}/sedumi
    ${INSTALL_DATA} ${WRKSRC}/*m ${PREFIX}/sedumi
.ifndef (NOPORTDOCS)
    ${MKDIR} ${DOCSDIR}
    ${INSTALL_DATA} ${WRKSRC}/*.txt ${DOCSDIR}
    ${INSTALL_DATA} ${WRKSRC}/doc/* ${DOCSDIR}
.endif
.ifndef (NOPORTEXAMPLES)
    ${MKDIR} ${EXAMPLESDIR}
    ${INSTALL_DATA} ${WRKSRC}/examples/* ${EXAMPLESDIR}
.endif
.include <bsd.port.mk>