summaryrefslogtreecommitdiff
blob: e6dd0f4caba2cadfb386d84e03cf5615788c1199 (plain)
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
# Copyright 1999-2000 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License, v2 or later
# Author Achim Gottinger <achim@gentoo.org>
# $Header: /var/cvsroot/gentoo-x86/net-fs/netatalk/netatalk-1.4_beta2-r1.ebuild,v 1.2 2000/09/15 20:09:08 drobbins Exp $

P=netatalk-1.4b2
A=${P}.tar.gz
S=${WORKDIR}/${P}
DESCRIPTION="Apple-Talk"
SRC_URI="ftp://terminator.rsug.itd.umich.edu/unix/netatalk/"${A}
HOMEPAGE="http://www.umich.edu/~rsug/netatalk/"

src_compile() {                           
  cd ${S}/include/netatalk
  cp endian.h endian.h.orig
  sed -e "s/<bytesex\.h>/<asm\/ioctls\.h>/" endian.h.orig > endian.h
  cd ${S}
  try make LDFLAGS="-lcrypt" OPTOPTS="${CFLAGS} -fsigned-char" DESTDIR=/usr 
ETCDIR=/etc/atalk \
	RESDIR=/usr/libexec/atalk SBINDIR=/usr/sbin
}

src_install() {                               
  cd ${S}
  dodir /etc/atalk
  dodir /usr/libexec
  into /usr

  dobin bin/aecho/aecho bin/getzones/getzones bin/megatron/megatron
  dobin bin/nbp/nbplkup bin/nbp/nbprgstr bin/nbp/nbpunrgstr
  dobin bin/pap/pap bin/pap/papstatus bin/psorder/psorder

  for i in single2bin unbin unhex unsingle hqx2bin macbinary
  do
    dosym /usr/bin/megatron /usr/bin/$i 
  done

  insinto /etc/atalk
  doins config/*

  dosbin etc/afpd/afpd etc/atalkd/atalkd etc/papd/papd 
  dosbin etc/psf/psa etc/psf/psf 
  cp etc/psf/etc2ps.sh ${D}/usr/sbin/etc2ps

  insinto /usr/include/atalk
  doins include/atalk/*

  insinto /usr/include/netatalk
  doins include/netatalk/*

  dolib.a libatalk/libatalk.a libatalk/libatalk_p.a

  doman man/man1/*.1 man/man3/*.3 man/man4/*.4 man/man8/*.8

  insinto /usr/libexec/atalk/filters

  doins etc/psf/pagecount.ps

  for i in ofpap ifpap tfpap ifpaprev tfpaprev ofwpap ifwpap ifwpaprev \
	   tfwpaprev ofmpap ifmpap tfmpap ifmpaprev tfmpaprev ofwmpap \
	   ifwmpap tfwmpap ifwmpaprev tfwmpaprev tfwpap
  do
	dosym /usr/sbin/psf /usr/libexec/atalk/filters/$i 
  done

  cd ${S}

  dodir /etc/rc.d/init.d
  cp ${O}/files/atalk ${D}/etc/rc.d/init.d/atalk
  dodoc BUGS CHANGES README* COPYRIGHT VERSION 

}