On Mon, Jan 22, 2018 at 09:08:30PM +0000, Christopher Baines wrote: > * gnu/packages/databases.scm (mongo-tools): New variable. Can you add some comments explaining the following section? > + (replace 'build > + (lambda* (#:key inputs outputs #:allow-other-keys) > + (let ((bash (which "bash")) > + (out (assoc-ref outputs "out"))) > + (let build ((tools > + '("bsondump" "mongodump" "mongoexport" "mongofiles" > + "mongoimport" "mongooplog" "mongorestore" > + "mongostat" "mongotop"))) > + (if (null? tools) > + #t > + (if (let* ((tool (car tools)) > + (command > + `("go" "install" "-v" > + "-tags=\"ssl sasl\"" > + "-ldflags" This -ldflags argument avoids the go-build-system's default ldflags, which strip the debugging symbols. Okay if that's what you intended. > + "-extldflags=-Wl,-z,now,-z,relro" > + ,(string-append > + "src/github.com/mongodb/mongo-tools/" > + tool "/main/" tool ".go")))) > + (simple-format #t "build: running ~A\n" > + (string-join command)) > + (zero? (apply system* command))) > + (build (cdr tools)) > + #f))))))))) Do you think the go-build-system should accept some sort of #:make-flags argument to simplify this sort of thing?