aboutsummaryrefslogtreecommitdiffstats
path: root/www/linux-netscape6/Makefile
blob: 4e708223cb0047fe464b10efb11b9a8204d735fb (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: netscape-linux-6
# Date created:         8 April 2000
# Whom:             sada@FreeBSD.org
#
# $FreeBSD$
#

PORTNAME=   linux-netscape
PORTVERSION=    6.0
CATEGORIES= www linux
MASTER_SITES=   ftp://ftp.netscape.com/pub/netscape6/english/6.0/unix/linux22/sea/
DISTNAME=   netscape-i686-pc-linux-gnu-sea

MAINTAINER= trevor@FreeBSD.org

RUN_DEPENDS=    ${LINUX_BASE}/lib/ld.so:${PORTSDIR}/emulators/linux_base \
        ${LINUX_BASE}/usr/lib/libgtk-1.2.so.0.5.0:${PORTSDIR}/x11-toolkits/linux-gtk \
        ${LINUX_BASE}/usr/lib/libjpeg.so.62.0.0:${PORTSDIR}/graphics/linux-jpeg

LINUX_BASE= /compat/linux
NO_BUILD=   yes
NO_FILTER_SHLIBS=   yes
ONLY_FOR_ARCHS= i386
USE_XLIB=   yes
WRKSRC= ${WRKDIR}/netscape-installer/xpi

INSTALL_DIR=    ${PREFIX}/lib/linux-netscape6
PLIST=      ${WRKDIR}/pkg-plist
STARTUP_CMD=    netscape6

do-extract:
    ${MKDIR} ${WRKSRC}
    @${TAR} xzf ${DISTDIR}/${DISTFILES} -C ${WRKDIR}
.for i in browser deflenus jre langenus mail psm spellchecker xpcom
    unzip -qo ${WRKSRC}/${i}.xpi -d ${WRKSRC}
.endfor
    ${MV} ${WRKSRC}/psm ${WRKSRC}/bin
    ${MV} ${WRKSRC}/jre-image-i386 ${WRKSRC}/bin/plugins/java2
    cd ${WRKSRC}/bin/plugins && ${LN} -s java2/plugin/i386/ns600/libjavaplugin_oji.so;
    ${MV} ${WRKSRC}/../license.txt ${WRKSRC}
.if !defined(NOPORTDOCS)
    ${MV} ${WRKSRC}/../README ${WRKSRC}
.endif

do-patch:
    ${TOUCH} ${TOUCH_FLAGS} ${WRKSRC}/bin/chrome/user-skins.rdf ${WRKSRC}/bin/chrome/user-locales.rdf
    ${CP} -p ${FILESDIR}/*rdf ${WRKSRC}/bin/chrome

do-configure:
    ${SETENV} $DISPLAY="NONE" ${WRKSRC}/bin/netscape file:///dev/null
    ${SED} -e "s;%%INSTALL_DIR%%;${INSTALL_DIR};g" \
    ${FILESDIR}/start.sh >${WRKDIR}/${STARTUP_CMD}

pre-install:
    ${ECHO} bin/${STARTUP_CMD} > ${PLIST}
    cd ${WRKSRC}/bin; for i in `find * \! -type d | sort`; do \
        ${ECHO} lib/linux-netscape6/$${i} >> ${PLIST}; \
        ${ECHO} $${i}; \
    done
    cd ${WRKSRC}/bin; \
    for i in `find -d * -type d`; do \
        ${ECHO} @dirrm lib/linux-netscape6/$${i} >> ${PLIST}; \
    done
    ${ECHO} @dirrm lib/linux-netscape6 >> ${PLIST}

do-install:
    ${MKDIR} ${INSTALL_DIR}
    ${CP} -Rp ${WRKSRC}/bin/* ${INSTALL_DIR}
    ${INSTALL_SCRIPT} ${WRKDIR}/${STARTUP_CMD} ${PREFIX}/bin
    ${CAT} ${WRKSRC}/license.txt

.include <bsd.port.mk>