Commit graph

14 commits

Author SHA1 Message Date
Jason A. Donenfeld 5d6083df7e Switch to go modules 2018-10-09 18:13:56 +02:00
Jason A. Donenfeld 6b3b1c3b91 version: bump snapshot 2018-06-13 16:22:16 +02:00
Jason A. Donenfeld a050431f26 Makefile: export PWD for OpenBSD's ksh(1)
Interestingly, ksh(1) on OpenBSD does not export PWD by default, and it
also has a notion of the "logical cwd" vs the "physical cwd", with the
latter being passed to chdir, but the former being stored in the
non-exported PWD and displayed to the user. This means that if you `cd`
into a directory that's comprised of symlinks, exec'd processes will see
the physical path. Observe:

  # ksh
  # mkdir a
  # ln -s a b
  # cd b
  # pwd
  /root/b
  # ksh -c pwd
  /root/a

The fact of separating physical and logical paths is not too uncommon
for shells (bash does it too), but not exporting PWD is very odd.

Since this is common behavior for many shells, libraries that return the
working directory will do something strange: they `stat(".")` and then
`stat(getenv("PWD"))`, and if these point to the same inode, they roll
with the value of `getenv("PWD")`, or otherwise fallback to asking the
kernel for the cwd.

Since PWD was not exported by ksh(1), Go's dep utility did not understand
it was operating inside of our faked GOPATH and became upset.

This patch works around the whole situation by simply exporting PWD
before executing dep.
2018-06-02 16:36:12 +02:00
Jason A. Donenfeld 625d59da14 Do not build on Linux 2018-05-24 16:41:42 +02:00
Jason A. Donenfeld 66f6ca3e4a Remove old makefile artifact 2018-05-24 03:13:46 +02:00
Jason A. Donenfeld 4a9de3218e Add undocumented --version flag 2018-05-24 02:25:36 +02:00
Jason A. Donenfeld 8a92a9109a Don't cause a new fake gopath to call dep 2018-05-23 17:31:06 +02:00
Jason A. Donenfeld 588b9f01ae Adopt GOPATH
GOPATH is annoying, but the Go community pushing me to adopt it is even
more annoying.
2018-05-23 05:18:13 +02:00
Jason A. Donenfeld fa003b6933 Discourage building for Linux 2018-05-20 03:19:03 +02:00
Jason A. Donenfeld 0e4ebfa194 Add vendoring for Homebrew 2018-05-15 14:49:52 +02:00
Jason A. Donenfeld 08d7602dc3 Improve makefile 2018-05-15 02:16:51 +02:00
Jason A. Donenfeld 7e10ebe101 Introduce rwcancel 2018-05-14 00:30:52 +02:00
Jason A. Donenfeld 2326d6a4d7 Odds and ends 2018-05-13 19:34:28 +02:00
Mathias Hall-Andersen a0f54cbe5a Align with go library layout 2018-02-04 16:08:26 +01:00
Renamed from src/Makefile (Browse further)