summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Kröning2019-07-11 13:46:15 +0200
committerMartin Kröning2019-07-11 14:05:10 +0200
commitfc1b1a11cf7abdf5eb408fa2428ca6c88c52629e (patch)
treeb02f986c52da8d633d23d0be551f037fa4e52801
downloadaur-fc1b1a11cf7abdf5eb408fa2428ca6c88c52629e.tar.gz
Initial commit
-rw-r--r--.SRCINFO18
-rw-r--r--.gitignore4
-rw-r--r--PKGBUILD41
-rw-r--r--make-fmv-patch-log-format.patch13
4 files changed, 76 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..ed6f1bd989f
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,18 @@
+pkgbase = make-fmv-patch-git
+ pkgdesc = Make FMV patch generator
+ pkgver = r15.a73d316
+ pkgrel = 1
+ url = https://github.com/clearlinux/make-fmv-patch
+ arch = any
+ license = MIT
+ makedepends = git
+ depends = perl
+ provides = make-fmv-patch
+ conflicts = make-fmv-patch
+ source = git+https://github.com/clearlinux/make-fmv-patch.git
+ source = make-fmv-patch-log-format.patch
+ sha256sums = SKIP
+ sha256sums = 396f194ba9a8a9f3680adfab742120506ee13263de89cb86e1570755e1551a25
+
+pkgname = make-fmv-patch-git
+
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 00000000000..9d2f76ddc5d
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,4 @@
+/src/
+/pkg/
+/make-fmv-patch
+/*.pkg.tar.xz \ No newline at end of file
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..9f6cfbb1ad2
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,41 @@
+# Maintainer: Martin Kröning <m dot kroening at hotmail dot de>
+pkgname=make-fmv-patch-git
+pkgver=r15.a73d316
+pkgrel=1
+pkgdesc='Make FMV patch generator'
+arch=('any')
+url="https://github.com/clearlinux/${pkgname%-git}"
+license=('MIT')
+depends=('perl' 'ctags' 'gcc>=6.0.0')
+makedepends=('git')
+provides=("${pkgname%-git}")
+conflicts=("${pkgname%-git}")
+source=("git+https://github.com/clearlinux/${pkgname%-git}.git"
+ "${pkgname%-git}-log-format.patch")
+sha256sums=('SKIP'
+ '396f194ba9a8a9f3680adfab742120506ee13263de89cb86e1570755e1551a25')
+
+pkgver() {
+ cd "$srcdir/${pkgname%-git}"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+prepare() {
+ cd "$srcdir/${pkgname%-git}"
+ patch -p1 -i "$srcdir/${pkgname%-git}-log-format.patch"
+}
+
+check() {
+ cd "$srcdir/${pkgname%-git}/tests"
+ make distclean all
+
+ cd "$srcdir/${pkgname%-git}"
+ [[ -n "$(perl make-fmv-patch.pl tests/loop-build.log tests)" ]]
+ [[ -n "$(perl make-fmv-patch.pl tests/max-build.log tests)" ]]
+}
+
+package() {
+ cd "$srcdir/${pkgname%-git}"
+ install -Dm755 make-fmv-patch.pl "$pkgdir/usr/bin/make-fmv-patch"
+ install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+}
diff --git a/make-fmv-patch-log-format.patch b/make-fmv-patch-log-format.patch
new file mode 100644
index 00000000000..c9dc3f8963a
--- /dev/null
+++ b/make-fmv-patch-log-format.patch
@@ -0,0 +1,13 @@
+diff --git a/make-fmv-patch.pl b/make-fmv-patch.pl
+index 69f7c3a..582b0c2 100644
+--- a/make-fmv-patch.pl
++++ b/make-fmv-patch.pl
+@@ -97,7 +97,7 @@ sub find_file {
+
+ open(BUILD_LOG, '<', "$log_file") or die $!;
+ while (<BUILD_LOG>) {
+- if($_ =~ /(\S+):([0-9]*):([0-9]*): note: (basic block|loop) (vectorized)/) {
++ if($_ =~ /(\S+):([0-9]*):([0-9]*): (optimized|note): (basic block|loop) (vectorized)/) {
+ $fmv->{s_name} = (split('/',$1))[-1];
+ $fmv->{f_name} = $1;
+ push @{$f{$1}->{v_line}},$2;