sys-kernel/dracut-crypt-ssh: Respect CC/LDFLAGS

Closes: https://bugs.gentoo.org/726014
Signed-off-by: Jakov Smolic <jakov.smolic@sartura.hr>
Signed-off-by: David Seifert <soap@gentoo.org>
This commit is contained in:
Jakov Smolic
2021-04-03 14:30:47 +02:00
committed by David Seifert
parent 0967f92e7e
commit f2db8522dc
2 changed files with 27 additions and 2 deletions

View File

@@ -1,8 +1,10 @@
# Copyright 1999-2020 Gentoo Authors
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit toolchain-funcs
DESCRIPTION="Early unlocking of encrypted systems via ssh for dracut"
HOMEPAGE="https://github.com/dracut-crypt-ssh/dracut-crypt-ssh"
SRC_URI="https://github.com/dracut-crypt-ssh/dracut-crypt-ssh/archive/v${PV}.tar.gz -> ${P}.tar.gz"
@@ -23,4 +25,9 @@ RDEPEND="${DEPEND}
)
net-misc/dropbear"
DOCS=("README.md")
PATCHES=( "${FILESDIR}"/${P}-ldflags.patch )
src_configure() {
tc-export CC
default
}

View File

@@ -0,0 +1,18 @@
# https://bugs.gentoo.org/726014
--- a/modules/60crypt-ssh/helper/Makefile
+++ b/modules/60crypt-ssh/helper/Makefile
@@ -17,11 +17,11 @@ clean:
rm -f *.o console_auth unlock crypttab-test
console_auth: auth.c
- $(CC) $(CFLAGS) $^ -o $@
+ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) $^ -o $@
unlock: crypttab.o unlock.o
- $(CC) $(CFLAGS) -lblkid $^ -o $@
+ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -lblkid $^ -o $@
crypttab-test: crypttab-test.c crypttab.o crypttab-test-data
- $(CC) crypttab-test.c $(CFLAGS) crypttab.o -lblkid -o crypttab-test
+ $(CC) crypttab-test.c $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) crypttab.o -lblkid -o crypttab-test
./crypttab-test