On Fri, Jun 14, 2019 at 03:11:55PM +0200, Tim Düsterhus wrote:
> These aliases still have the issue that the development headers are not
> necessarily installed, even if the distro has the headers available.

OK.

> I'm
> not sure whether there even is a need to change anything at all:
> 
> - The uneducated user will simply use whatever their distro maintainer
> (or third party repository maintainer) selects for them. They don't
> touch `make` at all.
> - The distro maintainer can be expected to be smart enough to take a
> look into the Makefile and enable all the options that are available on
> the distro.
> - The power user most likely wants to customize his build to include
> exactly what they need (e.g. disable Lua).
> 
> None of these groups would really benefit from a `linux-recent` target!

Indeed.

> Instead I suggest to:
> 
> 1. Add a `linux` target that is equivalent to `linux2628` (thus being
> equivalent to the linux-minimal from your suggestion above).

Then I'd rather call it "linux-glibc" in this case. I'm really having a
problem with conflating the kernel and the libc in fact. I'm fine with
considering they are both "recent enough" but seeing that the linux
target becomes totally unusable with uclibc, musl, dietlibc or any
possible alternative is a concern to me. And the USE_DL, USE_CRYPT,
USE_RT, USE_THREAD, USE_CRYPT_H are exclusively libc stuff and not
related to linux itself.

> 2. Remove all the other linux targets that target kernels from a
> bazillion years ago. If anyone actually has a need to run these AND also
> run a bleeding edge HAProxy they can be expected to be smart enough to
> use TARGET=generic and select all the other options.

I definitely agree. I think I've been keeping them for a long time
because I knew places where they were being used, and later just
because it took more effort to remove them than to leave them.

> If we really want to make it easy for users then we should add an
> autoconf script

Bah no thanks. You'll find another maintainer before we sink into this.
I already hate its face beyond imagination as a user, I don't even want
to meet its ass as a developer. I think it is the only tool ever created
in computer history which has consumed more human time to work around
than to write.

> that automatically spits out a line with all the
> supported options (and possibly `apt-get` commands to install the
> remaining headers that are not supported).

That's doable as suggestions for certain operating systems if needed,
though history shows that such suggestions generally don't remain
valid for a long time. In the mean time I've just added this to
"make help" at the end :

$ make help
TARGET not set.

Enabled features for TARGET '' (disable with 'USE_xxx=') :
  POLL

Disabled features for TARGET '' (enable with 'USE_xxx=1') :
  EPOLL KQUEUE MY_EPOLL MY_SPLICE NETFILTER PCRE PCRE_JIT PCRE2 PCRE2_JIT
  PRIVATE_CACHE THREAD PTHREAD_PSHARED REGPARM STATIC_PCRE STATIC_PCRE2
  TPROXY LINUX_TPROXY LINUX_SPLICE LIBCRYPT CRYPT_H VSYSCALL GETADDRINFO
  OPENSSL LUA FUTEX ACCEPT4 MY_ACCEPT4 ZLIB SLZ CPU_AFFINITY TFO NS
  DL RT DEVICEATLAS 51DEGREES WURFL SYSTEMD OBSOLETE_LINKER PRCTL
  THREAD_DUMP EVPORTS

$ make help TARGET=linux2628
Current TARGET: linux2628

Enabled features for TARGET 'linux2628' (disable with 'USE_xxx=') :
  EPOLL NETFILTER POLL THREAD TPROXY LINUX_TPROXY LINUX_SPLICE LIBCRYPT
  CRYPT_H FUTEX ACCEPT4 CPU_AFFINITY DL RT PRCTL THREAD_DUMP

Disabled features for TARGET 'linux2628' (enable with 'USE_xxx=1') :
  KQUEUE MY_EPOLL MY_SPLICE PCRE PCRE_JIT PCRE2 PCRE2_JIT PRIVATE_CACHE
  PTHREAD_PSHARED REGPARM STATIC_PCRE STATIC_PCRE2 VSYSCALL GETADDRINFO
  OPENSSL LUA MY_ACCEPT4 ZLIB SLZ TFO NS DEVICEATLAS 51DEGREES WURFL
  SYSTEMD OBSOLETE_LINKER EVPORTS

$ make help TARGET=mylinux
Current TARGET: mylinux (custom target)

Enabled features for TARGET 'mylinux' (disable with 'USE_xxx=') :
  POLL

Disabled features for TARGET 'mylinux' (enable with 'USE_xxx=1') :
  EPOLL KQUEUE MY_EPOLL MY_SPLICE NETFILTER PCRE PCRE_JIT PCRE2 PCRE2_JIT
  PRIVATE_CACHE THREAD PTHREAD_PSHARED REGPARM STATIC_PCRE STATIC_PCRE2
  TPROXY LINUX_TPROXY LINUX_SPLICE LIBCRYPT CRYPT_H VSYSCALL GETADDRINFO
  OPENSSL LUA FUTEX ACCEPT4 MY_ACCEPT4 ZLIB SLZ CPU_AFFINITY TFO NS
  DL RT DEVICEATLAS 51DEGREES WURFL SYSTEMD OBSOLETE_LINKER PRCTL
  THREAD_DUMP EVPORTS

It helped me immediately spot that I didn't enable DEVICEATLAS nor
51DEGREES yet in my default build scripts :-)

Ideas and opinions still welcome of course!
Willy

Reply via email to