From patchwork Mon May 8 11:34:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adolf Belka X-Patchwork-Id: 6841 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4QFK2g4y1qz3wlc for ; Mon, 8 May 2023 11:34:51 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4QFK2c0xFyz1LH; Mon, 8 May 2023 11:34:48 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4QFK2b4fkCz306Q; Mon, 8 May 2023 11:34:47 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4QFK2Z1MHjz2xZK for ; Mon, 8 May 2023 11:34:46 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4QFK2Y6c30zkc; Mon, 8 May 2023 11:34:45 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1683545686; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=EEf7tjYtvg8zHEw9tJUKFxdFf/fBYPJ55A1OmL04TdI=; b=EdkYcWiUV1Py5jkKIzFgub+4/MqdTsLDbFEuQ+fOIsEPzCQ3rg46Ipx74CgH9GM5KnM9kA MnJ6IuZuOHcWCQDA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1683545686; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=EEf7tjYtvg8zHEw9tJUKFxdFf/fBYPJ55A1OmL04TdI=; b=L6h/ckGbIcWbOJPa2/3qEF5xyyTZgEwvLGiaT3DfmheXBOtOmz/jI/uCAMulHRKPdGFuRn +sFVspcUELXWtJJwslZ9ycvQnN6cvBZ/oa3JgXfA2G5YeJRct0T3yr3a8pdH0Ahq7sS0DF SZHW/0SKJVk/e/XJ13/tGXdo7XnhQBnzlhLWjrfXEfRbmkkLA99HY++2bp1saw6CM0UcbG avIdCWKXpcgGRpwCNb9st89ojTJhK9D2dLKq3CWCtbWPSLxXubCB7F5zAkKscC7EShmnMY 5WM3ouHU8Mx+5iByw9ekfMPp0V3LUJT7Ek9lz4k9mHVqvaRWu0ypB7c01myxWg== From: Adolf Belka To: development@lists.ipfire.org Subject: [PATCH 2/2] libcap: Adjust the lfs file to place pkg-config files inj correct place Date: Mon, 8 May 2023 13:34:39 +0200 Message-Id: <20230508113439.2241-2-adolf.belka@ipfire.org> In-Reply-To: <20230508113439.2241-1-adolf.belka@ipfire.org> References: <20230508113439.2241-1-adolf.belka@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" - libcap places the files by default in /lib and not /usr/lib etc. To fix this libcap made a symlink for the library file from /lib to /usr/lib. However the .pc files were left in /lib/pkgconfig and not /usr/lib/pkgconfig and were therefore not found by the update of rng-tools which now required libcap to be found. - Changed the prefix settings for libcap which placed the libraries and .pc files in the correct locations while keeping the executables in their existing location. - This removed the need for symlinking /usr/lib/libcap.so to /lib/libcap.so.2.67 as the libraries are now placed in /usr/lib - Installed the ipfire build with these changes into a vm system and confirmed that everything worked. Input from Michael Tremer that if ping worked then libcap was functioning correctly. - The prefixes have to be applied to both make and make install to end up with the files in the correct places. Tested-by: Adolf Belka Signed-off-by: Adolf Belka --- config/rootfiles/common/libcap | 17 +++++++++-------- lfs/libcap | 13 ++++++++----- 2 files changed, 17 insertions(+), 13 deletions(-) diff --git a/config/rootfiles/common/libcap b/config/rootfiles/common/libcap index 194fc7f19..af1c22e83 100644 --- a/config/rootfiles/common/libcap +++ b/config/rootfiles/common/libcap @@ -1,11 +1,3 @@ -lib/libcap.so.2 -lib/libcap.so.2.67 -#lib/libpsx.so -#lib/libpsx.so.2 -lib/libpsx.so.2.67 -#lib/pkgconfig/libcap.pc -#lib/pkgconfig/libpsx.pc -lib/security/pam_cap.so sbin/capsh sbin/getcap sbin/getpcaps @@ -13,6 +5,15 @@ sbin/setcap #usr/include/sys/capability.h #usr/include/sys/psx_syscall.h usr/lib/libcap.so +usr/lib/libcap.so.2 +usr/lib/libcap.so.2.67 +#usr/lib/libpsx.so +#usr/lib/libpsx.so.2 +usr/lib/libpsx.so.2.67 +#usr/lib/pkgconfig/libcap.pc +#usr/lib/pkgconfig/libpsx.pc +#usr/lib/security +usr/lib/security/pam_cap.so #usr/share/man/man1/capsh.1 #usr/share/man/man3/cap_clear.3 #usr/share/man/man3/cap_clear_flag.3 diff --git a/lfs/libcap b/lfs/libcap index 9eab679ff..63f4ef8b0 100644 --- a/lfs/libcap +++ b/lfs/libcap @@ -72,10 +72,13 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE) # Prevent a static library from being installed cd $(DIR_APP) && sed -i '/install -m.*STA/d' libcap/Makefile - cd $(DIR_APP) && make GOLANG=no - cd $(DIR_APP) && make install GOLANG=no - rm -vf /lib/libcap.so - ln -svf /lib/libcap.so.2.67 /usr/lib/libcap.so - chmod +x /lib/libcap.so.* + cd $(DIR_APP) && make GOLANG=no \ + prefix=/usr \ + exec_prefix= \ + lib_prefix=/usr + cd $(DIR_APP) && make install GOLANG=no \ + prefix=/usr \ + exec_prefix= \ + lib_prefix=/usr @rm -rf $(DIR_APP) @$(POSTBUILD)