[squid-users] Recompiling Squid3 for Mips hardware, enabling captive portal?

Amos Jeffries squid3 at treenet.co.nz
Fri Sep 1 08:51:26 UTC 2017


On 01/09/17 19:36, David Mehler wrote:
> Hello,
> 
> I used Squid 2 a while back, when my networks were different.
> 
> I'm now wanting to implement squid 3.x. I've got an Asus Rt-N66U
> router, which I believe has a Mips processor on it.

That is something you will need to be sure of if you are unable to build 
Squid natively on the device. Squid can be cross-built from another 
machine, but you need to have used the right CPU-arch tuplets in the 
--host and --build cross-build options to run the resulting binaries.

If you don't already know what I mean by cross-build and tuplets you 
have some research to do before starting. :-)
OpenWRT has some fairly up to date info 
<https://forum.openwrt.org/viewtopic.php?id=52968>, not sure about Entware.


> I am wondering how
> to recompile Squid for Mips, or obtain the compilation script for the
> entware version of squid and recompile that?

CPU arch should only matter to your build tools so they can produce 
binaries that run on the device. That is a general code building thing.

The issues specifically with building Squid will be whether you have 
support in that devices OS for the Squid features you want to use.

Run 'squid -v' to retrieve the build options from an existing Squid if 
you have or can find one for the device. Then figure out which ones you 
want in your build.

> 
> My goal is to compile in helpers for squid as well as captive portal
> functionality.
> 
> Are there any helper libraries for squid3 to act as a captive portal?

Just the OS NAT interface. Sometimes that is a library (eg Linux 
netfilter), sometimes just the getsockopt() kernel API (eg OpenBSD).


Amos


More information about the squid-users mailing list