diff options
author | Quincy Fleming <quincyf467@protonmail.com> | 2023-07-18 12:56:49 -0500 |
---|---|---|
committer | Quincy Fleming <quincyf467@protonmail.com> | 2023-07-18 12:56:49 -0500 |
commit | 390eeecd09107fe1e175cb723d771162ee2e3d1b (patch) | |
tree | 43c780e96cf9dcba3b9a9a8cea0419237b59fc68 /dev-embedded | |
parent | app-emulation/LookingGlass: remove pulseaudio flag from libpulse (diff) | |
download | guru-390eeecd09107fe1e175cb723d771162ee2e3d1b.tar.gz guru-390eeecd09107fe1e175cb723d771162ee2e3d1b.tar.bz2 guru-390eeecd09107fe1e175cb723d771162ee2e3d1b.zip |
dev-embedded/qdl: respect user CFLAGS and LDFLAGS
Signed-off-by: Quincy Fleming <quincyf467@protonmail.com>
Diffstat (limited to 'dev-embedded')
-rwxr-xr-x | dev-embedded/qdl/files/qdl-1.0-makefile.patch | 17 | ||||
-rwxr-xr-x | dev-embedded/qdl/files/qdl-9999-makefile.patch | 17 | ||||
-rw-r--r-- | dev-embedded/qdl/qdl-1.0.ebuild | 13 | ||||
-rw-r--r-- | dev-embedded/qdl/qdl-9999.ebuild | 13 |
4 files changed, 53 insertions, 7 deletions
diff --git a/dev-embedded/qdl/files/qdl-1.0-makefile.patch b/dev-embedded/qdl/files/qdl-1.0-makefile.patch new file mode 100755 index 000000000..e6c7ab122 --- /dev/null +++ b/dev-embedded/qdl/files/qdl-1.0-makefile.patch @@ -0,0 +1,17 @@ +#Created by Quincy Fleming +#CFLAGS and LDFLAGS were not being respected +#Bug links: https://bugs.gentoo.org/910480 https://bugs.gentoo.org/910481 +--- a/Makefile ++++ b/Makefile +@@ -1,8 +1,8 @@ + OUT := qdl + +-CFLAGS := -O2 -Wall -g `xml2-config --cflags` +-LDFLAGS := `xml2-config --libs` +-prefix := /usr/local ++CFLAGS += `${PKG_CONFIG} --cflags libxml-2.0` ++LDFLAGS += `${PKG_CONFIG} --libs libxml-2.0 libudev` ++prefix = ${EPREFIX}/usr + + SRCS := firehose.c qdl.c sahara.c util.c patch.c program.c + OBJS := $(SRCS:.c=.o) diff --git a/dev-embedded/qdl/files/qdl-9999-makefile.patch b/dev-embedded/qdl/files/qdl-9999-makefile.patch new file mode 100755 index 000000000..a24de2b5c --- /dev/null +++ b/dev-embedded/qdl/files/qdl-9999-makefile.patch @@ -0,0 +1,17 @@ +#Created by Quincy Fleming +#CFLAGS and LDFLAGS were not being respected +#Bug links: https://bugs.gentoo.org/910480 https://bugs.gentoo.org/910481 +--- a/Makefile ++++ b/Makefile +@@ -1,8 +1,8 @@ + OUT := qdl + +-CFLAGS := -O2 -Wall -g `pkg-config --cflags libxml-2.0` +-LDFLAGS := `pkg-config --libs libxml-2.0 libudev` +-prefix := /usr/local ++CFLAGS += `${PKG_CONFIG} --cflags libxml-2.0` ++LDFLAGS += `${PKG_CONFIG} --libs libxml-2.0 libudev` ++prefix = ${EPREFIX}/usr + + SRCS := firehose.c qdl.c sahara.c util.c patch.c program.c ufs.c + OBJS := $(SRCS:.c=.o) diff --git a/dev-embedded/qdl/qdl-1.0.ebuild b/dev-embedded/qdl/qdl-1.0.ebuild index 5e2fb597a..90d2b54ed 100644 --- a/dev-embedded/qdl/qdl-1.0.ebuild +++ b/dev-embedded/qdl/qdl-1.0.ebuild @@ -3,6 +3,8 @@ EAPI=8 +inherit toolchain-funcs + DESCRIPTION="Tool to communicate with Qualcomm System On a Chip bootroms" HOMEPAGE="https://github.com/andersson/qdl" SRC_URI="https://github.com/andersson/qdl/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" @@ -12,13 +14,18 @@ SLOT="0" KEYWORDS="~amd64" BDEPEND="virtual/libudev + virtual/pkgconfig dev-libs/libxml2 " -src_install() { - emake DESTDIR="${D}" prefix="${EPREFIX}"/usr install +PATCHES=( "${FILESDIR}/${P}-makefile.patch" ) - dodoc README +src_compile() { + emake CC=$(tc-getCC) PKG_CONFIG=$(tc-getPKG_CONFIG) +} + +src_install() { + default insinto "/usr/share/${PN}" doins LICENSE } diff --git a/dev-embedded/qdl/qdl-9999.ebuild b/dev-embedded/qdl/qdl-9999.ebuild index 7f17fadec..d1c29872e 100644 --- a/dev-embedded/qdl/qdl-9999.ebuild +++ b/dev-embedded/qdl/qdl-9999.ebuild @@ -3,7 +3,7 @@ EAPI=8 -inherit git-r3 +inherit git-r3 toolchain-funcs DESCRIPTION="Tool to communicate with Qualcomm System On a Chip bootroms" HOMEPAGE="https://github.com/andersson/qdl" @@ -13,13 +13,18 @@ LICENSE="BSD-3" SLOT="0" BDEPEND="virtual/libudev + virtual/pkgconfig dev-libs/libxml2 " -src_install() { - emake DESTDIR="${D}" prefix="${EPREFIX}"/usr install +PATCHES=( "${FILESDIR}/${P}-makefile.patch" ) + +src_compile() { + emake CC=$(tc-getCC) PKG_CONFIG=$(tc-getPKG_CONFIG) +} - dodoc README +src_install() { + default insinto "/usr/share/${PN}" doins LICENSE } |