aboutsummaryrefslogtreecommitdiffstats
path: root/x11-wm/alloywm/Makefile
blob: b40ca4785bf5e7ae9a425a50b06b9cadf0f0eb97 (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
# New ports collection makefile for:    alloywm
# Date created:             2002-01-20
# Whom:                 trevor
#
# $FreeBSD$
#

PORTNAME=   alloywm
PORTVERSION=    0.4.0
PORTREVISION=   1
CATEGORIES= x11-wm
MASTER_SITES=   http://www.phatboydesigns.net/devel/

MAINTAINER= trevor@FreeBSD.org
COMMENT=Has title bars, shading, resizing, automatic placement, window list

BROKEN=     Incorrect SHA hash

HAS_CONFIGURE=  yes
PLIST=      ${WRKDIR}/pkg-plist
USE_GMAKE=  yes
USE_X_PREFIX=   yes
WANT_GNOME= yes
USE_REINPLACE=  yes
REINPLACE_ARGS= -i'' -E
SCRIPTS=    ${WRKSRC}/scriptdir

pre-configure:
    ${FIND} ${WRKSRC} \( -name '*.in' -or -name configure \) -exec \
        ${REINPLACE_CMD} 's:bash:sh:g ; \
        s:gtk-config:${GTK_CONFIG}:g' {} \;
    ${RM} -f ${WRKSRC}/*/Makefile
    ${CHMOD} +x ${WRKSRC}/configure

do-build:
    cd ${WRKSRC}/goodies && ${GMAKE}
.for ii in client events main misc new screen widgets
    cd ${WRKSRC}/src && ${CC} -c ${CFLAGS} -I${X11BASE}/include \
        ${ii}.c
.endfor
    cd ${WRKSRC}/src && ${CC} ${CFLAGS} -DSHAPE -o alloywm \
        -L${X11BASE}/lib -lXext -lX11 \
        client.o events.o main.o misc.o new.o screen.o widgets.o

pre-install:
    cd ${WRKSRC} && ${FIND} * -type f -perm 755 | cut -f 2 -d / | \
        ${SED} "s:^:bin/:g" > ${PLIST}
    ${FIND} ${SCRIPTS} \! -name '*in' -type f | \
        ${SED} "s:^${SCRIPTS}:bin:g" >> ${PLIST}
.if !defined(NOPORTDOCS)
.for i in Changelog README
    ${ECHO_CMD} share/doc/alloywm/${i} >> ${PLIST}
.endfor
    ${ECHO_CMD} @dirrm share/doc/alloywm >> ${PLIST}
.endif

do-install:
.if !defined(NOPORTDOCS)
    ${MKDIR} ${DOCSDIR}
    ${INSTALL_DATA} ${WRKSRC}/Changelog ${WRKSRC}/README ${DOCSDIR}
.endif
    ${FIND} ${SCRIPTS} \! -name '*in' -type f -exec \
        ${INSTALL_SCRIPT}  {} ${PREFIX}/bin \;
    ${FIND} ${WRKSRC} -type f -perm 755 \
        -exec ${INSTALL_PROGRAM} {} ${PREFIX}/bin \;

.include <bsd.port.pre.mk>
.if ${HAVE_GNOME:Mgtk12}!=""
USE_GNOME+= gtk12
PKGNAMESUFFIX=  -gtk
.endif
.include <bsd.port.post.mk>