mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 03:30:05 +02:00
Add recipe for haiku-format 18.1.7 (#10573)
This commit is contained in:
@@ -1,63 +0,0 @@
|
||||
SUMMARY="Code formatter for Haiku coding style"
|
||||
DESCRIPTION="Format C/C++ code following the Haiku Coding Guidelines.
|
||||
|
||||
This is a superset of clang-format with customizations that implement the coding style followed by \
|
||||
Haiku and several applications running on Haiku.
|
||||
|
||||
haiku-format looks for a configuration file '.haiku-format', going up the file hierarchy starting \
|
||||
with the folder of the file you want to format. This optional configuration file can be used to \
|
||||
override any default Haiku style options."
|
||||
HOMEPAGE="https://github.com/owenca/haiku-format"
|
||||
COPYRIGHT="2003-2019 University of Illinois at Urbana-Champaign
|
||||
2018-2023 Owen Pan"
|
||||
LICENSE="Apache v2 with LLVM Exception"
|
||||
REVISION="1"
|
||||
srcGitRev="b72750011837a2b148921d99e3b7fac7adb36fa8"
|
||||
SOURCE_URI="https://github.com/owenca/llvm-project/archive/$srcGitRev.tar.gz"
|
||||
SOURCE_DIR="llvm-project-$srcGitRev"
|
||||
CHECKSUM_SHA256="a537c2858a8e80a617c9279525b65a4d04ac7d8634751d1137a6136058980b33"
|
||||
|
||||
ARCHITECTURES="all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
haiku_format$secondaryArchSuffix = $portVersion
|
||||
cmd:git_haiku_format = $portVersion
|
||||
cmd:haiku_format = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:cmake
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ninja
|
||||
cmd:python3
|
||||
cmd:sed
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
cmake -S llvm -B build -G Ninja \
|
||||
-DLLVM_ENABLE_PROJECTS=clang \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_SKIP_RPATH=On \
|
||||
-Wno-dev
|
||||
|
||||
ninja -C build clang-format
|
||||
strip -sv build/bin/clang-format
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
mkdir -pv $prefix/bin
|
||||
cp -fv build/bin/clang-format $prefix/bin/haiku-format
|
||||
|
||||
gitHaikuFormat=$prefix/bin/git-haiku-format
|
||||
sed s/clang-format/haiku-format/g clang/tools/clang-format/git-clang-format > $gitHaikuFormat
|
||||
chmod -v +x $gitHaikuFormat
|
||||
}
|
||||
@@ -12,10 +12,10 @@ COPYRIGHT="2003-2019 University of Illinois at Urbana-Champaign
|
||||
2018-2024 Owen Pan"
|
||||
LICENSE="Apache v2 with LLVM Exception"
|
||||
REVISION="1"
|
||||
srcGitRev="d715369f5eb9669a1a278ffa3ee9fd47fd8d1aae"
|
||||
SOURCE_URI="https://github.com/owenca/llvm-project/archive/$srcGitRev.tar.gz"
|
||||
srcGitRev="haiku-$portVersion"
|
||||
SOURCE_URI="https://github.com/owenca/llvm-project/archive/refs/tags/$srcGitRev.tar.gz"
|
||||
CHECKSUM_SHA256="1462bc3ad75cd8e0cd11300500d34a4b4c84ccecc06b91eb740f84222f304d0e"
|
||||
SOURCE_DIR="llvm-project-$srcGitRev"
|
||||
CHECKSUM_SHA256="4341226425d3a37c2c85e6aaa11b4d82e453e0e3eaa0e95b9db220aa8e89a172"
|
||||
|
||||
ARCHITECTURES="all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
Reference in New Issue
Block a user