diff --git a/dev-util/astyle/astyle-2.05.recipe b/dev-util/astyle/astyle-2.05.recipe deleted file mode 100644 index 5e8ff700a..000000000 --- a/dev-util/astyle/astyle-2.05.recipe +++ /dev/null @@ -1,57 +0,0 @@ -SUMMARY="A source code formatter and beautifier for C, C++, C# and Java" -DESCRIPTION=" -Artistic Style is a filter written in C++ that automatically re-indents and \ -re-formats C / C++ / C# / Java source files. It can be used from a command \ -line, or it can be incorporated as classes in another C++ program. -" -HOMEPAGE="http://astyle.sourceforge.net" -COPYRIGHT=" -1998-2002 by Tal Davidson \ -2006-2013 Jim Pattee -" -LICENSE="GNU LGPL v3" -REVISION="2" -SOURCE_URI="http://sourceforge.net/projects/astyle/files/astyle/astyle%20${portVersion}/astyle_${portVersion}_linux.tar.gz" -CHECKSUM_SHA256="da34eb1f8f12e6f50f1cf674944c0db70c91b203008e11be0f57aa8267823a39" -SOURCE_DIR="astyle" - -ARCHITECTURES="all !x86_gcc2" -if [ "$targetArchitecture" = x86_gcc2 ]; then -SECONDARY_ARCHITECTURES="x86" -fi - -# On x86_gcc2 we don't want to install the commands in bin//, but in bin/. -commandBinDir=$binDir -if [ "$targetArchitecture" = x86_gcc2 ]; then - commandBinDir=$prefix/bin -fi - -PROVIDES=" - astyle$secondaryArchSuffix = $portVersion - cmd:astyle = $portVersion - " - -REQUIRES=" - haiku$secondaryArchSuffix - " - -BUILD_PREREQUIRES=" - haiku${secondaryArchSuffix}_devel - cmd:make - cmd:g++$secondaryArchSuffix - " - -BUILD() -{ - cd build/gcc - make prefix=$prefix -} - -INSTALL() -{ - cd build/gcc - make install \ - prefix=$prefix \ - SYSCONF_PATH=$docDir \ - INSTALL=install -} diff --git a/dev-util/astyle/astyle-3.1.recipe b/dev-util/astyle/astyle-3.4.8.recipe similarity index 62% rename from dev-util/astyle/astyle-3.1.recipe rename to dev-util/astyle/astyle-3.4.8.recipe index 3f1ea7ad6..7cfaaf56c 100644 --- a/dev-util/astyle/astyle-3.1.recipe +++ b/dev-util/astyle/astyle-3.4.8.recipe @@ -4,13 +4,14 @@ re-indents and re-formats C / C++ / C# / Java source files. It can be used \ from a command line, or it can be incorporated as classes in another \ C++ program." HOMEPAGE="http://astyle.sourceforge.net" -COPYRIGHT="1998-2002 by Tal Davidson - 2006-2018 Jim Pattee" +COPYRIGHT="1998-2002 Tal Davidson + 2006-2018 Jim Pattee + 2023 The Artistic Style Authors" LICENSE="GNU LGPL v3" REVISION="1" -SOURCE_URI="https://downloads.sf.net/astyle/astyle_${portVersion}_linux.tar.gz" -CHECKSUM_SHA256="cbcc4cf996294534bb56f025d6f199ebfde81aa4c271ccbd5ee1c1a3192745d7" -SOURCE_DIR="astyle" +SOURCE_URI="https://downloads.sf.net/astyle/astyle-$portVersion.tar.bz2" +CHECKSUM_SHA256="0f32cb097dc121099cca420a0762c62297d5a5dbc8b994fc755cb47ff4c6c666" +PATCHES="astyle-$portVersion.patchset" ARCHITECTURES="all !x86_gcc2 ?x86 ?arm ?ppc" if [ "$targetArchitecture" = x86_gcc2 ]; then @@ -40,15 +41,19 @@ BUILD_PREREQUIRES=" BUILD() { - cd build/gcc - make prefix=$prefix + make -C build/gcc prefix=$prefix $jobArgs } INSTALL() { - cd build/gcc - make install \ + make -C build/gcc install \ prefix=$prefix \ SYSCONF_PATH=$docDir \ INSTALL=install + + mkdir -pv $dataDir/bash-completion/completions + cp -afv sh-completion/astyle.bash $dataDir/bash-completion/completions/astyle + + mkdir -pv $dataDir/zsh/site-functions + cp -afv sh-completion/astyle.zsh $dataDir/zsh/site-functions/_astyle } diff --git a/dev-util/astyle/patches/astyle-3.4.8.patchset b/dev-util/astyle/patches/astyle-3.4.8.patchset new file mode 100644 index 000000000..6d622c2e8 --- /dev/null +++ b/dev-util/astyle/patches/astyle-3.4.8.patchset @@ -0,0 +1,22 @@ +From 5b291ee2b419412d765884b53c82dae50587dd84 Mon Sep 17 00:00:00 2001 +From: Chris Roberts +Date: Tue, 26 Sep 2023 12:41:04 -0600 +Subject: zsh completion fix + + +diff --git a/sh-completion/astyle.zsh b/sh-completion/astyle.zsh +index b54e86d..20ad9d4 100644 +--- a/sh-completion/astyle.zsh ++++ b/sh-completion/astyle.zsh +@@ -54,7 +54,7 @@ _astyle() { + "--remove-comment-prefix[Remove the leading '*' prefix on multi-line comments and indent the comment text one indent]" + "--max-code-length[Break the line if it exceeds more than # characters]: :_files" + "--break-after-logical[After break line using --max-code-length, place logical conditional last on the previous line]" +- "mode[Set input syntax mode]: :(c java cs objc js)" ++ "--mode[Set input syntax mode]: :(c java cs objc js)" + "--pad-method-prefix[Insert space padding after the '-' or '+' Objective-C method prefix]" + "--unpad-method-prefix[Remove all space padding after the '-' or '+' Objective-C method prefix]" + "--pad-return-type[Insert space padding after the Objective-C return type]" +-- +2.39.2 +