python3Packages.orjson: Disable failing tests on 32 bit
[NixPkgs.git] / pkgs / tools / misc / tlp / patches / 0001-makefile-correctly-sed-paths.patch
blobbe8afc0667fad7164a234d4e9a342693500af6f6
1 From 5c5d878bf49bae5920c330482217477819ba9bc2 Mon Sep 17 00:00:00 2001
2 From: Bernardo Meurer <bernardo@meurer.org>
3 Date: Fri, 15 Oct 2021 23:22:50 -0700
4 Subject: [PATCH 1/2] makefile: correctly sed paths
6 The default Makefile for tlp makes a mess with catenating `DESTDIR` to
7 everything, but then not actualy using the catenated (_ prefixed)
8 variables to sed it's `.in` files.
10 This patch makes sure that it correctly sets the paths, taking `DESTDIR`
11 in account where it makes sense (e.g. /bin where we want $out/bin) but
12 not where it doesn't (/etc/tlp.conf should be just that).
14 The reason DESTDIR is used at all, as opposed to the more appropriate
15 PREFIX, is covered in the nix formula, and is (also) due to the Makefile
16 being a bit "different."
17 ---
18 Makefile | 18 +++++++++---------
19 1 file changed, 9 insertions(+), 9 deletions(-)
21 diff --git a/Makefile b/Makefile
22 index e9bbab4..ab05720 100644
23 --- a/Makefile
24 +++ b/Makefile
25 @@ -51,19 +51,19 @@ _TPACPIBAT = $(DESTDIR)$(TPACPIBAT)
27 SED = sed \
28 -e "s|@TLPVER@|$(TLPVER)|g" \
29 - -e "s|@TLP_SBIN@|$(TLP_SBIN)|g" \
30 - -e "s|@TLP_TLIB@|$(TLP_TLIB)|g" \
31 - -e "s|@TLP_FLIB@|$(TLP_FLIB)|g" \
32 - -e "s|@TLP_ULIB@|$(TLP_ULIB)|g" \
33 - -e "s|@TLP_BATD@|$(TLP_BATD)|g" \
34 + -e "s|@TLP_SBIN@|$(_SBIN)|g" \
35 + -e "s|@TLP_TLIB@|$(_TLIB)|g" \
36 + -e "s|@TLP_FLIB@|$(_FLIB)|g" \
37 + -e "s|@TLP_ULIB@|$(_ULIB)|g" \
38 + -e "s|@TLP_BATD@|$(_BATD)|g" \
39 -e "s|@TLP_CONFUSR@|$(TLP_CONFUSR)|g" \
40 -e "s|@TLP_CONFDIR@|$(TLP_CONFDIR)|g" \
41 - -e "s|@TLP_CONFDEF@|$(TLP_CONFDEF)|g" \
42 - -e "s|@TLP_CONFREN@|$(TLP_CONFREN)|g" \
43 - -e "s|@TLP_CONF@|$(TLP_CONF)|g" \
44 + -e "s|@TLP_CONFDEF@|$(_CONFDEF)|g" \
45 + -e "s|@TLP_CONFREN@|$(_CONFREN)|g" \
46 + -e "s|@TLP_CONF@|$(_CONF)|g" \
47 -e "s|@TLP_RUN@|$(TLP_RUN)|g" \
48 -e "s|@TLP_VAR@|$(TLP_VAR)|g" \
49 - -e "s|@TPACPIBAT@|$(TPACPIBAT)|g"
50 + -e "s|@TPACPIBAT@|$(_TPACPIBAT)|g"
52 INFILES = \
53 tlp \
54 --
55 2.33.0