tisdag 21 november 2006

rdfind on mac os x 10.4

I got an email from a mac user who had trouble installing rdfind on mac os x.
Rdfind is a tool to find duplicate files which I wrote a year ago or so.
It uses a library called nettle for checksum calculation, which complicates things a bit.
Here is a output of how to do it, step by step. It assumes you downloaded and nettle source code to a subdirectory called ~/Downloaded/nettle-1.14 in the example. Also, rdfind source code is downloaded to ~/Downloaded/rdfind-1.2.2.

[jt@Hobbes jt]$ mkdir src
[jt@Hobbes jt]$ mv Downloaded/nettle-1.14 src/.
[jt@Hobbes jt]$ cd src
[jt@Hobbes src]$ cd nettle-1.14/
[jt@Hobbes nettle-1.14]$ ./configure
checking build system type... powerpc-apple-darwin8.8.0
.
.
.
config.status: creating nettle-stdint.h : __NETTLE_STDINT_H
[jt@Hobbes nettle-1.14]$ make
make all-here
.
.
.
gcc -g -O2 -ggdb3 -Wno-pointer-sign -Wall -W -Wmissing-prototypes -
Wmissing-declarations -Wstrict-prototypes -Wpointer-arith -Wbad-
function-cast -Wnested-externs -L.. nettle-benchmark.o nettle-
openssl.o io.o \
-lnettle -lcrypto -o nettle-benchmark
[jt@Hobbes nettle-1.14]$
[jt@Hobbes nettle-1.14]$ cd ..
[jt@Hobbes src]$ ln -s nettle-1.14 nettle
[jt@Hobbes src]$ mv ~/Downloaded/rdfind-1.2.2 .
[jt@Hobbes src]$ cd rdfind-1.2.2/
[jt@Hobbes rdfind-1.2.2]$ ./configure CPPFLAGS=-I.. LDFLAGS=-L../nettle
checking for a BSD-compatible install... /sw/bin/install -c
.
.
.
config.status: executing default-1 commands
[jt@Hobbes rdfind-1.2.2]$ make
g++ -DHAVE_CONFIG_H -I. -I. -I. -I.. -g -O2 -c rdfind.cc
g++ -DHAVE_CONFIG_H -I. -I. -I. -I.. -g -O2 -c Checksum.cc
g++ -DHAVE_CONFIG_H -I. -I. -I. -I.. -g -O2 -c Dirlist.cc
g++ -DHAVE_CONFIG_H -I. -I. -I. -I.. -g -O2 -c Fileinfo.cc
g++ -DHAVE_CONFIG_H -I. -I. -I. -I.. -g -O2 -c Rdutil.cc
g++ -g -O2 -L../nettle -o rdfind rdfind.o Checksum.o Dirlist.o
Fileinfo.o Rdutil.o -lstdc++ -lnettle
[jt@Hobbes rdfind-1.2.2]$

Inga kommentarer: