[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

squid internet object cache and various how-to questions

I'm making a debian package of the Squid Internet Object Cache (the 
freeware descendant of the now-commercial Harvest Cached).  Useful for
people who want to run apache but need a proxy cache as well.

I've got the package ready in very simple form, but it has no fancy
postinst scripts or anything to do auto-configuration etc.  I've just
started running it myself, so I wouldn't even know where to start doing
auto config stuff yet...that'll have to wait until I have a better feel
for the package.

I have set up it's conffiles: /etc/squid.conf and /etc/init.d/squid - a 
first for me, none of my previous packages really required conffiles.  
Learn something new every day :-)

OK, what I want to know is, should I release this now, or should I wait 
until I've got time to do some smarter postinst stuff like grepping for 
hostname and inserting that in /etc/squid.conf etc etc etc.

My thoughts are that this sort of refinement can wait until 2nd release.

I hope no-one else is working on this.  If so, they're quite welcome to
have the package...I'm just packaging it because I think it's useful
(and I want to switch from cern to apache but can't until I get a
replacement proxy/cache)

Oh, another question.  How do people generally handle Makefiles &
autoconf stuff that doesn't quite fit into debian's FSSTND?  

Not knowing much about autoconf, I just hacked the various Makefile.in
files to insert $(debprefix) before $(bindir) etc in relevant places
such as the install rule, and also make sure that log files went to
/var/log/squid/* rather than squid's $(localstatedir)/logs.

Then I build the binary with debprefix undefined, and install it with


    $(MAKE) all

    debprefix=../debian-tmp/ $(MAKE) install

This works for me, and seems like a reasonably elegant solution (i.e.
minimal changes to the original source)....just wondering if anyone has
a better/cleaner/tidier way?

This setup allows configure to be re-run without losing the debian 
changes to the Makefiles.

Also, I suppose it's a good idea to run 'make realclean' to clean up the 
autoconf stuff before making the source archive or the .diff.gz file?  
Not doing this could cause some confusion/difficulties for porters to 
other architectures.

Finally, someone suggested a while ago for my tkdesk package that I make 
it architecture independant by using:

    arch := $(shell uname -m)

Don't do this.  It doesn't work.  On my machine, it returns i486.  I
guess on a pentium it would produce Pentium.  What's the recommended way
of doing this?  For now I've just hardcoded "arch := i386".  I don't
want to do it this way.


Reply to: