Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 22 Jan 2006 07:59:15 -0500 (EST)
From:      "Jeffrey H. Johnson" <CPE1704TKS@bellsouth.net>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        CPE1704TKS@bellsouth.net
Subject:   ports/92156: [NEW PORT] sysutils/phantom: Phantomblock generator (converts existing files to sparse files)
Message-ID:  <20060122125915.4C1EB39833@offworld.cqasys.com>
Resent-Message-ID: <200601221530.k0MFU4Zu009026@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         92156
>Category:       ports
>Synopsis:       [NEW PORT] sysutils/phantom: Phantomblock generator (converts existing files to sparse files)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sun Jan 22 15:30:04 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Jeffrey H. Johnson
>Release:        FreeBSD 6.0-STABLE i386
>Organization:
>Environment:
System: FreeBSD offworld.cqasys.com 6.0-STABLE FreeBSD 6.0-STABLE #21: Wed Jan 18 22:35:45 EST 2006
>Description:
This tool removes blocks of 0x00 from files by replacing them with 
phantomblocks. That way, a file uses less diskspace while its contents 
hasn't changed at all!

BEWARE: after copying these files with tar, cp, cpio or any other tool, 
the phantomblocks have been replaced with 0x00-blocks again!

EXAMPLE: 

find / -type f -print | xargs -n 1 phantom -r -i

This would go trough the whole harddisk, scan all files and generate 
0x00-blocks where necessary.

WWW: http://www.vanheusden.com/Linux/phantom.php

Generated with FreeBSD Port Tools 0.63
>How-To-Repeat:
>Fix:

--- phantom-1.2.shar begins here ---
# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#	phantom
#	phantom/files
#	phantom/files/patch-aa
#	phantom/Makefile
#	phantom/distinfo
#	phantom/pkg-descr
#
echo c - phantom
mkdir -p phantom > /dev/null 2>&1
echo c - phantom/files
mkdir -p phantom/files > /dev/null 2>&1
echo x - phantom/files/patch-aa
sed 's/^X//' >phantom/files/patch-aa << 'END-of-phantom/files/patch-aa'
X*** Makefile.orig	Sun Jan 22 07:05:29 2006
X--- Makefile	Sun Jan 22 07:43:31 2006
X***************
X*** 1,20 ****
X  VERSION=1.2
X  
X  DEBUG=#-g
X! LDFLAGS=$(DEBUG)
X! CFLAGS=-O2 -Wall -DVERSION=\"$(VERSION)\" $(DEBUG)
X  
X  OBJS=phantom.o
X  
X  all: phantom
X  
X  phantom: $(OBJS)
X  	$(CC) -Wall -W $(OBJS) $(LDFLAGS) -o phantom
X  
X  install: phantom
X! 	cp phantom $(DESTDIR)/usr/bin
X  
X  clean:
X  	rm -f $(OBJS) core phantom
X  
X  package: clean
X--- 1,20 ----
X  VERSION=1.2
X  
X  DEBUG=#-g
X! LDFLAGS+=$(DEBUG)
X! CFLAGS+=-DVERSION=\"$(VERSION)\" -DMADV_SEQUENTIAL $(DEBUG)
X  
X  OBJS=phantom.o
X  
X  all: phantom
X  
X  phantom: $(OBJS)
X  	$(CC) -Wall -W $(OBJS) $(LDFLAGS) -o phantom
X  
X  install: phantom
X! 	${INSTALL} -m 755 phantom ${PREFIX}/bin
X  
X  clean:
X  	rm -f $(OBJS) core phantom
X  
X  package: clean
END-of-phantom/files/patch-aa
echo x - phantom/Makefile
sed 's/^X//' >phantom/Makefile << 'END-of-phantom/Makefile'
X# New ports collection makefile for:    phantom
X# Date created:         22 January 2006
X# Whom:                 Jeffrey H. Johnson <CPE1704TKS@bellsouth.net>
X#
X# $FreeBSD: ports/sysutils/phantom/Makefile,v 1.00 2006/01/22 07:44:41 trn Exp $
X#
X
XPORTNAME=	phantom
XPORTVERSION=	1.2
XCATEGORIES=	sysutils
XMASTER_SITES=	http://www.vanheusden.com/Linux/
XEXTRACT_SUFX=	.tgz
X
XMAINTAINER=	CPE1704TKS@bellsouth.net
XCOMMENT=	Phantomblock generator (converts existing files to sparse files)
X
XALL_TARGET=	all
X
XPLIST_FILES=	bin/phantom
X
X.include <bsd.port.mk>
END-of-phantom/Makefile
echo x - phantom/distinfo
sed 's/^X//' >phantom/distinfo << 'END-of-phantom/distinfo'
XSIZE (phantom-1.2.tgz) = 4425
XMD5 (phantom-1.2.tgz) = d790abb0caed787e3c8082340e6e549e
XSHA256 (phantom-1.2.tgz) = 9ce7d0d7e6561474a0b4d70f9ae0fb4010ef9b4f012c9018bf9fdca1704ac6c2
END-of-phantom/distinfo
echo x - phantom/pkg-descr
sed 's/^X//' >phantom/pkg-descr << 'END-of-phantom/pkg-descr'
XThis tool removes blocks of 0x00 from files by replacing them with 
Xphantomblocks. That way, a file uses less diskspace while its contents 
Xhasn't changed at all!
X
XBEWARE: after copying these files with tar, cp, cpio or any other tool, 
Xthe phantomblocks have been replaced with 0x00-blocks again!
X
XEXAMPLE: 
X
Xfind / -type f -print | xargs -n 1 phantom -r -i
X
XThis would go trough the whole harddisk, scan all files and generate 
X0x00-blocks where necessary.
X
XWWW: http://www.vanheusden.com/Linux/phantom.php
END-of-phantom/pkg-descr
exit
--- phantom-1.2.shar ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060122125915.4C1EB39833>