aboutsummaryrefslogtreecommitdiffstats
path: root/devel/dmalloc/Makefile
blob: c6df7b21d77692da060ad5125715f09f14923d16 (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
# New ports collection makefile for:    dmalloc
# Date created:         7 December 2000
# Whom:             Jeremy Shaffner <jeremy@external.org>
#
# $FreeBSD$

PORTNAME=   dmalloc
PORTVERSION=    4.8.1
CATEGORIES= devel
MASTER_SITES=   ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= dmalloc
EXTRACT_SUFX=   .tgz

# Original from: Gray Watson http://256.com/gray/email.html
MAINTAINER= jeremy@external.org

INSTALLS_SHLIB= YES
GNU_CONFIGURE=  YES
CONFIGURE_ARGS+=--enable-threads --enable-shlib

# NOTE: we make the test program first because otherwise it screws up
# and tried to use the .so instead of the .a for some stupid reason
ALL_TARGET= dmalloc_t all light

pre-patch:
    @${PERL} -pi -e 's|-lpthread|-pthread|g' ${WRKSRC}/configure

do-install:
    ${INSTALL_PROGRAM} ${WRKSRC}/dmalloc ${PREFIX}/bin
    ${INSTALL_DATA} ${WRKSRC}/dmalloc.h ${PREFIX}/include
    ${INSTALL_DATA} ${WRKSRC}/libdmallocthcxx.so ${PREFIX}/lib/libdmallocthcxx.so.1
    @${LN} -sf ${PREFIX}/lib/libdmallocthcxx.so.1 ${PREFIX}/lib/libdmallocthcxx.so
    ${INSTALL_DATA} ${WRKSRC}/libdmallocthcxx.a ${PREFIX}/lib
    ${INSTALL_DATA} ${WRKSRC}/libdmallocth.so ${PREFIX}/lib/libdmallocth.so.1
    @${LN} -sf ${PREFIX}/lib/libdmallocth.so.1 ${PREFIX}/lib/libdmallocth.so
    ${INSTALL_DATA} ${WRKSRC}/libdmallocth.a ${PREFIX}/lib
    ${INSTALL_DATA} ${WRKSRC}/libdmalloc.so ${PREFIX}/lib/libdmalloc.so.1
    @${LN} -sf ${PREFIX}/lib/libdmalloc.so.1 ${PREFIX}/lib/libdmalloc.so
    ${INSTALL_DATA} ${WRKSRC}/libdmalloc.a ${PREFIX}/lib
    ${INSTALL_DATA} ${WRKSRC}/libdmalloclp.a ${PREFIX}/lib
.if !defined(NOPORTDOCS)
    @${MKDIR} ${PREFIX}/share/doc/dmalloc
    ${INSTALL_DATA} ${WRKSRC}/dmalloc.html ${PREFIX}/share/doc/dmalloc
.endif

post-install:
    ${INSTALL_DATA} ${WRKSRC}/dmalloc.info ${PREFIX}/info
    @install-info ${PREFIX}/info/dmalloc.info ${PREFIX}/info/dir

.include <bsd.port.mk>