Commit graph

8 commits

Author SHA1 Message Date
Alyssa Ross 4de8cbfb16 bmake.passthru.setupHook: set some defaults
These are all read from the environment by the default bmake
stdlib (e.g. <bsd.prog.mk>, <bsd.own.mk>).  Some of the default
values (like building cat pages instead of man pages, or stripping
binaries when installing) don't really make sense for Nixpkgs, so we
override them here for every build using bmake.

Eventually I'd like to unify the bmake setupHook and the NetBSD make
setupHook, but not today.
2021-06-09 12:44:43 +00:00
embr a75c0a7f87 bozohttpd: experimental darwin compat patch
As far as I can tell, libSystem on darwin provides a libm compatibility
symlink, but not a libcrypt one.

Prior art (eg. CPython) appears to use `stdenv.isDarwin` as a proxy for
`stdenv.hostPlatform.libc == "libSystem"`, but the latter also works in
cases where we're building on Darwin, but with eg. musl for some reason.
2021-05-31 11:03:17 +02:00
embr ee4b583ae8 bozohttpd: minor formatting
The Nix style guide isn't exactly comprehensive, but this at least seems
slightly closer to the examples:

https://nixos.org/manual/nixpkgs/stable/#sec-syntax

I'm annoyed that nixpkgs-fmt as of writing won't accept:

  COPTS = [
    # ...
  ] ++ optional (...) "..."
    ++ optional (...) "...";

...which seems to be the actual convention, looking at eg. pkgs.nginx.
2021-05-31 10:47:49 +02:00
embr f4f05481e3 bozohttpd: add bozohttpd-minimal target 2021-05-26 11:38:57 +02:00
embr dc9165346e bozohttpd: resolve warnings, serve >2GB files on 32bit host
-D_DEFAULT_SOURCE *and* -D_GNU_SOURCE together resolve all warnings
about implicitly defined functions.

-D_LARGEFILE_SOURCE and -D_FILE_OFFSET_BITS=64 enable gcc's Large File
Extensions to allow a 32-bit host to serve files larger than 2GB.

Based on what Makefile.boot does, for platforms without bmake:
http://cvsweb.netbsd.org/bsdweb.cgi/src/libexec/httpd/Makefile.boot
2021-05-26 11:21:01 +02:00
embr 77acedc33b bozohttpd: remove unnecessary checkFlags 2021-05-24 13:35:38 +02:00
embr 28508dce6a bozohttpd: use bmake flags instead of a custom installPhase 2021-05-24 13:35:09 +02:00
embr caaee8a55e bozohttpd: init 2021-05-24 00:41:45 +02:00