commit 343c31f99ab38777f77f4ecb3290c068eb3b47795f9c360dd2dbbd89bee8a267 Author: Matthias Mailänder Date: Sun Mar 15 14:44:36 2015 +0000 Accepting request 290848 from home:jengelh:dev OBS-URL: https://build.opensuse.org/request/show/290848 OBS-URL: https://build.opensuse.org/package/show/science/gperiodic?expand=0&rev=1 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/all.diff b/all.diff new file mode 100644 index 0000000..950a9a2 --- /dev/null +++ b/all.diff @@ -0,0 +1,41 @@ +From: Jan Engelhardt +Date: 2015-03-15 11:57:37.631698089 +0100 + +fix blatant errors + +gcc: +gperiodic.c: In function 'menu_file_exit': +gperiodic.c:169:1: warning: control reaches end of non-void function [-Wreturn-type] + } +gperiodic.c: In function 'main_prog': +gperiodic.c:481:9: warning: 'buff' may be used uninitialized in this function [-Wmaybe-uninitialized] + free(buff); + +rpmlint: +I: Program returns random data in a function +E: gperiodic no-return-in-nonvoid-function gperiodic.c:169 +--- + gperiodic.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +Index: gperiodic-3.0.0/gperiodic.c +=================================================================== +--- gperiodic-3.0.0.orig/gperiodic.c ++++ gperiodic-3.0.0/gperiodic.c +@@ -166,6 +166,7 @@ void display_element_dialog( GtkWidget * + GCallback menu_file_exit(void) + { + main_window_exit(NULL,NULL); ++ return NULL; + } + + +@@ -321,7 +322,7 @@ void main_prog(void) + int menu_num_items; + GdkColor tooltip_color_bg, tooltip_color_fg; + int red, gree, blue; +- char *buff; ++ char *buff = NULL; + int i; + + GtkWidget *menubar; diff --git a/gperiodic-3.0.0.tar.gz b/gperiodic-3.0.0.tar.gz new file mode 100644 index 0000000..a8190c4 --- /dev/null +++ b/gperiodic-3.0.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8ca5d2b8b415e391d3d3b0b03585cff87e3aadfd95584a8db0e8dd953cd1cd8e +size 302543 diff --git a/gperiodic.changes b/gperiodic.changes new file mode 100644 index 0000000..543840e --- /dev/null +++ b/gperiodic.changes @@ -0,0 +1,4 @@ +------------------------------------------------------------------- +Sun Mar 15 14:26:39 UTC 2015 - jengelh@inai.de + +- Initial package (version 3.0.0) for build.opensuse.org diff --git a/gperiodic.spec b/gperiodic.spec new file mode 100644 index 0000000..5ea9145 --- /dev/null +++ b/gperiodic.spec @@ -0,0 +1,63 @@ +# +# spec file for package gperiodic +# +# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# + + +Name: gperiodic +Version: 3.0.0 +Release: 0 +Summary: A program for looking up data of elements from the periodic table +License: GPL-2.0+ +Group: Productivity/Scientific/Chemistry +Url: http://frantz.fi/software/gperiodic.php + +Source: http://download.sf.net/gperiodic/%name-%version.tar.gz +Patch1: all.diff +BuildRoot: %{_tmppath}/%{name}-%{version}-build +BuildRequires: pkgconfig(gtk+-2.0) +BuildRequires: intltool + +%description +GPeriodic is a program for looking up data of elements from the +periodic table. This program also features a non-graphical interface. + +%lang_package + +%prep +%setup -q +%patch -P 1 -p1 + +%build +perl -i -pe 's{^\tmake\b}{\t\$(MAKE)}g' Makefile # reenable parallel build +make %{?_smp_mflags} CFLAGS="%optflags" + +%install +%make_install +%find_lang %name + +%files +%defattr(-,root,root) +%_bindir/gperiodic +%_mandir/man1/gperiodic* +%_datadir/applications/gperiodic* +%_datadir/icons/* +%_datadir/pixmaps/gperiodic* +%doc gpl.txt + +%files lang -f %name.lang +%defattr(-,root,root) + +%changelog