Package Details: include-what-you-use 0.21-2

Git Clone URL: https://aur.archlinux.org/include-what-you-use.git (read-only, click to copy)
Package Base: include-what-you-use
Description: A tool for use with clang to analyze #includes in C and C++ source files
Upstream URL: https://include-what-you-use.org
Keywords: c c++ format header include iwyu
Licenses: LicenseRef-LLVM-Release-License
Submitter: Mindless
Maintainer: sebschrader (jetm)
Last Packager: jetm
Votes: 43
Popularity: 1.63
First Submitted: 2011-12-03 05:58 (UTC)
Last Updated: 2024-03-26 21:39 (UTC)

Pinned Comments

jetm commented on 2023-11-10 00:05 (UTC) (edited on 2024-05-03 13:16 (UTC) by jetm)

IWYU v0.22 is out, but clang v18 has not been released in Arch Linux. Please don't flag out-of-date until the new clang version is available. Thanks.

Latest Comments

1 2 3 4 5 6 7 Next › Last »

djrollins commented on 2024-03-30 08:49 (UTC)

Apologies, I flagged as out-of-date before I saw your comment on clang18.

jetm commented on 2024-03-26 21:39 (UTC)

Updated PKGBUILD with all the suggestions. Thanks!

Porous3247 commented on 2024-03-26 18:10 (UTC)

Note: version 0.22 doesn't build properly with llvm17, must wait until clang/llvm 18 is available in Arch Linux

aperez commented on 2024-02-23 09:00 (UTC) (edited on 2024-02-23 09:03 (UTC) by aperez)

This wasn't building for me in a clean chroot, so I took a chance to simplify the package, the following worked for me:

diff --git a/PKGBUILD b/PKGBUILD
index 4ce4d1b..b4e3744 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -8,10 +8,10 @@ _clang_major=16
 _clang_minor=0
 _clang_ver="${_clang_major}.${_clang_minor}"
 pkgdesc="A tool for use with clang to analyze #includes in C and C++ source files"
-url="http://include-what-you-use.org"
+url="https://include-what-you-use.org"
 license=('LLVM Release License')
-source=("https://github.com/${pkgname}/${pkgname}/archive/${pkgver}.tar.gz")
-sha512sums=('77195dc36338a37d3397c78701d81e52fc1c6a3441979fa016f154b0fc860598959e6430e78a51bbf9049f6b2bb62956e50f5531ac5c94c6554e2383ace540f5')
+source=("${url}/downloads/${pkgname}-${pkgver}.src.tar.gz")
+sha512sums=('618445c4b2aa8a33b0b4985b284f3778a5532667cbaac22f23d9061cd17a3223761655d413b6fc93fa2f9c0b35645f475babec3e321c91ef6a5177fea6543281')
 arch=('x86_64')
 _min="${_clang_ver}"
 _max=$((_clang_major + 1)).0
@@ -20,27 +20,16 @@ makedepends=("clang>=${_min}" "clang<${_max}" "cmake" "llvm>=${_min}" "llvm<${_m
 install=iwyu.install

 build() {
-   cd "${srcdir}/${pkgname}-${pkgver}"
-   rm -rf build && mkdir build && cd build
-   cmake -G "Ninja" ../
-  ninja
+   rm -rf build
+   cmake -Wno-dev -GNinja -S"${pkgname}" -Bbuild --install-prefix /usr
+  cmake --build build
 }

 package() {
-   cd "${srcdir}/${pkgname}-${pkgver}/build"
+   DESTDIR="${pkgdir}" cmake --install build
+   mv -v "${pkgdir}/usr/bin"/{fix_includes.py,iwyu-fix-includes}
+   mv -v "${pkgdir}/usr/bin"/{iwyu_tool.py,iwyu-tool}

-   DESTDIR="${pkgdir}" ninja install
-
-   install -Dm755 ../fix_includes.py "${pkgdir}/usr/bin/iwyu-fix-includes"
-   install -Dm755 ../iwyu_tool.py "${pkgdir}/usr/bin/iwyu-tool"
-
-  # ninja
-   mv "${pkgdir}/usr/local/bin/include-what-you-use" "${pkgdir}/usr/bin/include-what-you-use"
-  mv "${pkgdir}/usr/local/share" "${pkgdir}/usr"
-   rm -f "${pkgdir}/usr/local/bin/fix_includes.py"
-   rm -f "${pkgdir}/usr/local/bin/iwyu_tool.py"
-  rmdir "${pkgdir}/usr/local/bin"
-  rmdir "${pkgdir}/usr/local"
 }

 # vim:set ts=2 sw=2 et:

jetm commented on 2023-11-10 00:05 (UTC) (edited on 2024-05-03 13:16 (UTC) by jetm)

IWYU v0.22 is out, but clang v18 has not been released in Arch Linux. Please don't flag out-of-date until the new clang version is available. Thanks.

lahwaacz commented on 2023-09-05 16:11 (UTC) (edited on 2023-09-05 16:11 (UTC) by lahwaacz)

@xeruf The llvm/clang packages in official Arch Linux repositories were recently updated to version 16, so you don't have to compile it yourself. Of course, if you use a different distribution, you need to ask elsewhere.

xeruf commented on 2023-09-05 11:07 (UTC) (edited on 2023-09-05 11:08 (UTC) by xeruf)

This package, supposedly installed for compilation of some other package to make it smaller, was giving me headaches due to its clang and llvm >= 16 dependency which resulted in hours of compilation of llvm-git which never finished. Removed it for now.

Is there no way to make these requirements less strict?

flaviut commented on 2023-08-29 14:27 (UTC)

Update to 0.20 with clang v16:

diff --git a/PKGBUILD b/PKGBUILD
index 35a458b..4ce4d1b 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,16 +2,16 @@
 # Old Maintainer: Manuel Mendez <mmendez534@gmail.com>

 pkgname=include-what-you-use
-pkgver=0.19
+pkgver=0.20
 pkgrel=1
-_clang_major=15
+_clang_major=16
 _clang_minor=0
 _clang_ver="${_clang_major}.${_clang_minor}"
 pkgdesc="A tool for use with clang to analyze #includes in C and C++ source files"
 url="http://include-what-you-use.org"
 license=('LLVM Release License')
 source=("https://github.com/${pkgname}/${pkgname}/archive/${pkgver}.tar.gz")
-sha512sums=('0847ae898696b51540ab9f5715e69bae67db42409d60205227d543ba6597b12cc2ea5bf68a3315c31f22e7186e05c06a86f5ae5b893c23bfe4cd9ef6f06ccddc')
+sha512sums=('77195dc36338a37d3397c78701d81e52fc1c6a3441979fa016f154b0fc860598959e6430e78a51bbf9049f6b2bb62956e50f5531ac5c94c6554e2383ace540f5')
 arch=('x86_64')
 _min="${_clang_ver}"
 _max=$((_clang_major + 1)).0

Spixmaster commented on 2023-08-29 12:19 (UTC)

The package clang was just updated to version 16.

Score_Under commented on 2023-01-20 16:17 (UTC) (edited on 2023-01-20 16:18 (UTC) by Score_Under)

Arch has updated to clang 15 now