added community/codeblocks

This commit is contained in:
Kevin Mihelich 2022-04-26 02:53:37 +00:00
parent a419882feb
commit 4c116e109f
3 changed files with 84 additions and 0 deletions

View file

@ -0,0 +1,23 @@
From: =?utf-8?q?David_Pr=C3=A9vot?= <taffit@debian.org>
Date: Thu, 2 Apr 2020 16:51:48 -1000
Subject: Protect asm("int3") if defined(LOGGING)
This hopefully fixes FTBFS on non Intel arch.
---
src/plugins/contrib/dragscroll/dragscrollcfg.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/plugins/contrib/dragscroll/dragscrollcfg.h b/src/plugins/contrib/dragscroll/dragscrollcfg.h
index 7fc28be..fbff8a8 100644
--- a/src/plugins/contrib/dragscroll/dragscrollcfg.h
+++ b/src/plugins/contrib/dragscroll/dragscrollcfg.h
@@ -35,7 +35,9 @@ class cbDragScrollCfg: public cbConfigurationPanel
wxString GetBitmapBaseName() const;
void OnApply();
void OnCancel(){}
+#if defined(LOGGING)
virtual void InitDialog(){ asm("int3");} /*trap*/
+#endif
// pointer to owner of the configuration diaglog needed to
// complete the OnApply/OnCancel EndModal() logic

View file

@ -0,0 +1,48 @@
# Maintainer: Balló György <ballogyor+arch at gmail dot com>
# Contributor: Alexander F Rødseth <xyproto@archlinux.org>
# Contributor: Bartłomiej Piotrowski <nospam@bpiotrowski.pl>
# Contributor: Robert Hollencamp <rhollencamp@gmail.com>
# Contributor: Daniel J Griffiths <griffithsdj@inbox.com>
# Contributor: Stefan Husmann <stefan-husmann@t-online.de>
# Contributor: Roman Mikhayloff <rimf@inbox.ru>
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
# - patch from debian to fix ARM FTBFS
pkgname=codeblocks
pkgver=20.03
pkgrel=2
pkgdesc='Cross-platform C/C++ IDE'
arch=('x86_64')
url='http://codeblocks.org/'
license=('GPL3')
depends=('boost-libs' 'wxgtk3' 'hunspell')
makedepends=('boost' 'imagemagick' 'zip')
source=("https://downloads.sourceforge.net/codeblocks/$pkgname-$pkgver.tar.xz"
codeblocks-gcc11.patch
0003-Protect-asm-int3-if-defined-LOGGING.patch)
sha256sums=('15eeb3e28aea054e1f38b0c7f4671b4d4d1116fd05f63c07aa95a91db89eaac5'
'10b2b08440adc447d1d23eb122fa37beff1f26b9d7588b83f8435721586f4ed1'
'6911f64558eaf10526d4940db228c2941f86b5075b2ef8d05027a36ebed1ddf4')
prepare() {
cd $pkgname-$pkgver
convert src/mime/codeblocks.png +set date:create +set date:modify -background none -extent 64x64 src/mime/codeblocks.png
sed -i 's|$(datadir)/pixmaps|$(datadir)/icons/hicolor/64x64/apps|' src/mime/Makefile.{am,in}
sed -i 's|$(datarootdir)/appdata|$(datarootdir)/metainfo|' Makefile.{am,in} src/plugins/contrib/appdata/Makefile.{am,in}
patch -p1 < ../codeblocks-gcc11.patch # Fix build with GCC 11 (Fedora)
patch -p1 < ../0003-Protect-asm-int3-if-defined-LOGGING.patch # Fix builds on ARM (Debian)
}
build() {
cd $pkgname-$pkgver
./configure --prefix=/usr --with-contrib-plugins=all,-FileManager --with-wx-config=/usr/bin/wx-config-gtk3
sed -i 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
make
}
package() {
cd $pkgname-$pkgver
make DESTDIR="$pkgdir" install
}

View file

@ -0,0 +1,13 @@
diff --git a/src/plugins/openfileslist/openfileslistplugin.h b/src/plugins/openfileslist/openfileslistplugin.h
index 7fd7a95..87b08ee 100644
--- a/src/plugins/openfileslist/openfileslistplugin.h
+++ b/src/plugins/openfileslist/openfileslistplugin.h
@@ -23,7 +23,7 @@ struct TargetFilesData
// Functor for the std::set predicate to sort the opened editor files according to their tab order
struct compareLess
{
- bool operator()(const ProjectFile* lhs, const ProjectFile* rhs) { return lhs->editorTabPos < rhs->editorTabPos; }
+ bool operator()(const ProjectFile* lhs, const ProjectFile* rhs) const { return lhs->editorTabPos < rhs->editorTabPos; }
};
typedef std::set<ProjectFile*, compareLess> OpenFilesSet;
ProjectFile* activeFile;