- Timestamp:
- 02/20/12 14:05:37 (13 years ago)
- Files:
-
- trunk/ports/net/macathena-machtype/Portfile (modified) (1 diff)
- trunk/ports/net/macathena-machtype/files/getSysnameList.py (modified) (1 diff)
- trunk/ports/net/macathena-machtype/files/patch-config.guess (deleted)
- trunk/ports/net/macathena-machtype/files/patch-config.sub (deleted)
- trunk/ports/net/macathena-machtype/files/patch-machtype_linux.sh (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/ports/net/macathena-machtype/Portfile
r36 r201 3 3 4 4 name macathena-machtype 5 version 200308125 version svn25436 6 6 distname machtype-${version} 7 7 categories net 8 8 maintainers mit.edu:sipb-macathena 9 description Hesiod is the Project Athena service name resolution protocol9 description Provides basic information about the running system 10 10 platforms darwin 11 11 master_sites http://macathena.mit.edu/dist/ 12 patchfiles patch-configure.in \ 13 patch-machtype_linux.sh \ 14 patch-config.sub \ 15 patch-config.guess 16 checksums md5 377829b5da0c05cf334d2fa2e9124c4f \ 17 sha1 ea18209e214b35238ed31955c6ceb1fbabcfdcb2 \ 18 rmd160 021db450b6af4aaa3e46eab678c01e5bcc9cfa4b 12 patchfiles patch-machtype_linux.sh \ 13 patch-configure.in 14 checksums md5 d01a977c9c6d5b74aa9c0d888d963c28 \ 15 sha1 427dad33c2589136b36b87fd2f4a0d737e61320d \ 16 rmd160 efc130d5cd2cb334f610bffe110b867d52cca519 19 17 20 18 use_autoconf yes 21 19 22 configure.env-append ATHENA_MAJOR_VERSION= 9\23 ATHENA_MINOR_VERSION= 420 configure.env-append ATHENA_MAJOR_VERSION=10 \ 21 ATHENA_MINOR_VERSION=0 24 22 25 23 depends_lib port:macathena-base 26 24 25 depends_build port:automake 26 27 27 destroot.violate_mtree yes 28 28 29 post-patch { 30 file copy ${prefix}/share/automake-1.11/install-sh ${worksrcpath}/ 31 file copy ${prefix}/share/automake-1.11/mkinstalldirs ${worksrcpath}/ 32 file copy ${prefix}/share/automake-1.11/config.sub ${worksrcpath}/ 33 file copy ${prefix}/share/automake-1.11/config.guess ${worksrcpath}/ 34 } 35 29 36 configure.env-append [exec ${filespath}/getSysnameList.py] trunk/ports/net/macathena-machtype/files/getSysnameList.py
r10 r201 6 6 darwin_ver = int(getoutput('uname -r').split('.')[0]) * 10 7 7 8 ver_list = range(darwin_ver, 40, -10)8 ver_list = range(darwin_ver, 70, -10) 9 9 x86_list = ["x86_darwin_%d" % ver for ver in ver_list] 10 10 ppc_list = ["ppc_darwin_%d" % ver for ver in ver_list] 11 11 12 if arch == 'i386': 12 if arch == 'i386' and darwin_ver >= 110: 13 versions = x86_list 14 elif arch == 'i386': 13 15 versions = [item for items in zip(x86_list, ppc_list) for item in items] 14 16 else: 15 17 versions = ppc_list 16 18 17 versions += ['share', 'common', 'any' ]19 versions += ['share', 'common', 'any', 'all'] 18 20 19 21 print 'ATHENA_SYS=%s ATHENA_SYS_COMPAT="%s"' % (versions[0], ':'.join(versions[1:])) trunk/ports/net/macathena-machtype/files/patch-machtype_linux.sh
r10 r201 1 --- machtype_linux.sh.orig 20 07-12-24 21:51:18.000000000 -06002 +++ machtype_linux.sh 20 07-12-25 00:20:57.000000000 -06001 --- machtype_linux.sh.orig 2011-10-28 17:31:43.000000000 -0400 2 +++ machtype_linux.sh 2012-02-20 12:33:57.000000000 -0500 3 3 @@ -1,4 +1,4 @@ 4 4 -#!/bin/sh 5 5 +#!/bin/bash 6 # $Id: machtype_linux.sh,v 1.9 2003 /08/12 21:47:50 jweiss Exp $6 # $Id: machtype_linux.sh,v 1.9 2003-08-12 21:47:50 jweiss Exp $ 7 7 8 8 # We need to support the following options: 9 @@ - 86,7 +86,7 @@9 @@ -91,7 +91,7 @@ 10 10 fi 11 11 … … 16 16 fi 17 17 18 @@ -1 33,32 +133,31@@18 @@ -145,27 +145,26 @@ 19 19 fi 20 20 21 21 if [ $display ] ; then 22 - /sbin/lspci | awk -F: '/VGA/ {print $3}' | sed -n -e 's/^ //' -e p22 - lspci | awk -F: '/VGA/ {print $3}' | sed -n -e 's/^ //' -e p 23 23 + system_profiler SPDisplaysDataType | awk 'NR==3 { print }' | sed "s/^ *\(.*\):$/\1/" 24 24 printed=1 … … 26 26 27 27 if [ $rdsk ]; then 28 - awk '/^SCSI device/ { print; } 29 - /^hd[a-z]:/ { print; } 30 - /^Floppy/ { for (i=3; i <= NF; i += 3) print $i ": " $(i+2); }' \ 31 - /var/log/dmesg 28 - for d in /sys/block/[fhs]d*; do 29 - echo $(basename "$d"): \ 30 - $(xargs -I @ expr @ '*' 8 / 15625 < "$d/size")MB \ 31 - $(cat "$d/device/model" || 32 - cat "/proc/ide/$(basename "$d")/model") 33 - done 2>/dev/null 32 34 + disks=`ls /dev/disk* | grep 'disk[0-9]*$'` 33 35 + for disk in $disks … … 42 44 + usermem=$(($(sysctl -n hw.usermem)/1024)) 43 45 if [ $verbose ]; then 44 - awk 'BEGIN { FS="[^0-9]+" } 45 - /^Memory:/ { printf "user=%d, phys=%d (%d M)\n", 46 - $2*1.024, $3*1.024, $3/1000; }' \ 47 - /var/log/dmesg 46 - awk '/^MemTotal:/ { printf "user=%d, phys=%d (%d M)\n", 47 - $2, $2, $2/1024 }' \ 48 - /proc/meminfo 48 49 + printf "user=%d, phys=%d (%d M)\n" $usermem $physmem $((physmem/1024)) 49 50 else 50 - awk 'BEGIN { FS="[^0-9]+" } 51 - /^Memory:/ { printf "%d\n", $3*1.024; }' /var/log/dmesg 51 - awk '/^MemTotal:/ { printf "%d\n", $2 }' /proc/meminfo 52 52 + echo $physmem 53 53 fi 54 54 printed=1 55 fi 56 @@ -182,6 +181,6 @@ 55 57 fi 56 58