summary refs log tree commit diff
path: root/gnu/packages/ftp.scm
diff options
context:
space:
mode:
authorTobias Geerinckx-Rice <me@tobias.gr>2021-07-02 04:40:01 +0200
committerTobias Geerinckx-Rice <me@tobias.gr>2021-07-02 07:14:09 +0200
commit4049fa8e52ced1fab2d6d013ffa45e819e3c8676 (patch)
tree72dd1e78ce32be35e1eb41b10e9d4417bbe9f4a2 /gnu/packages/ftp.scm
parenta841d8e8b3f300953061383e7caf5bc1f1585a35 (diff)
downloadguix-4049fa8e52ced1fab2d6d013ffa45e819e3c8676.tar.gz
gnu: vsftpd: Honour upstream make flags.
* gnu/packages/ftp.scm (vsftpd)[arguments]: Add a new 'append-make-flags
phase.  Remove our now redundant "-pie" from LDFLAGS.
Diffstat (limited to 'gnu/packages/ftp.scm')
-rw-r--r--gnu/packages/ftp.scm9
1 files changed, 8 insertions, 1 deletions
diff --git a/gnu/packages/ftp.scm b/gnu/packages/ftp.scm
index f8ac54eb4d..c79991e3af 100644
--- a/gnu/packages/ftp.scm
+++ b/gnu/packages/ftp.scm
@@ -270,10 +270,17 @@ directory comparison and more.")
     (build-system gnu-build-system)
     (arguments
      `(#:make-flags
-       (list "LDFLAGS=-lcap -lcrypt -lpam -pie")
+       (list "LDFLAGS=-lcap -lcrypt -lpam")
        #:tests? #f                      ; no test suite
        #:phases
        (modify-phases %standard-phases
+         (add-after 'unpack 'append-make-flags
+           (lambda _
+             (substitute* "Makefile"
+               (("(CFLAGS|LDFLAGS)[[:blank:]]*=" _ variable)
+                (format #f "UPSTREAM_~a +=" variable))
+               (("\\$\\((CFLAGS|LDFLAGS)\\)" _ variable)
+                (format #f "$(UPSTREAM_~a) $(~@*~a)" variable)))))
          (add-after 'unpack 'patch-installation-directory
            (lambda* (#:key outputs #:allow-other-keys)
              (substitute* "Makefile"