1 %include /usr/lib/rpm/macros.java
2 Summary: The Most Intelligent Ruby and Rails IDE
6 # TODO: figure out what's the licensing and redistribution
8 Group: Development/Tools
9 Source0: http://download.jetbrains.com/ruby/RubyMine-%{version}.tar.gz
10 # NoSource0-md5: 271068d44ad9249e4b3be3533232d336
12 Source1: %{name}.desktop
14 URL: http://www.jetbrains.com/ruby/
15 BuildRequires: jpackage-utils
16 BuildRequires: rpm-javaprov
17 BuildRequires: rpmbuild(macros) >= 1.300
18 Requires: desktop-file-utils
24 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26 # use /usr/lib, 64bit files do not conflict with 32bit files (64 suffix)
27 # this allows to install both arch files and to use 32bit jdk on 64bit os
28 %define _appdir %{_prefix}/lib/%{name}
33 %setup -qn RubyMine-%{version}
35 # keep only single arch files (don't want to pull 32bit deps by default),
36 # if you want to mix, install rpm from both arch
39 rm bin/libyjpagent-linux64.so
40 rm bin/rubymine64.vmoptions
41 rm bin/libbreakgen64.so
45 rm bin/libyjpagent-linux.so
46 rm bin/rubymine.vmoptions
50 chmod a+rx bin/*.so bin/fsnotifier*
54 # cleanup backups after patching
55 find '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f
58 rm -rf $RPM_BUILD_ROOT
59 install -d $RPM_BUILD_ROOT{%{_appdir},%{_bindir},%{_pixmapsdir},%{_desktopdir}}
60 cp -l build.txt $RPM_BUILD_ROOT/cp-test && l=l && rm -f $RPM_BUILD_ROOT/cp-test
61 cp -p rubymine.png $RPM_BUILD_ROOT%{_pixmapsdir}/%{name}.png
62 cp -p RMlogo.svg $RPM_BUILD_ROOT%{_pixmapsdir}/%{name}.svg
63 cp -a$l bin help lib license plugins rb rubystubs* $RPM_BUILD_ROOT%{_appdir}
64 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
65 ln -s %{_appdir}/bin/rubymine.sh $RPM_BUILD_ROOT%{_bindir}/rubymine
68 rm -rf $RPM_BUILD_ROOT
71 %update_desktop_database
74 %update_desktop_database
77 %defattr(644,root,root,755)
78 %attr(755,root,root) %{_bindir}/%{name}
87 %{_appdir}/bin/rubymine*.vmoptions
88 %{_appdir}/bin/idea.properties
89 %{_appdir}/bin/log.xml
90 %attr(755,root,root) %{_appdir}/bin/rubymine.sh
91 %attr(755,root,root) %{_appdir}/bin/rinspect.sh
92 %attr(755,root,root) %{_appdir}/bin/fsnotifier*
93 %attr(755,root,root) %{_appdir}/bin/libyjpagent-linux*.so
94 %attr(755,root,root) %{_appdir}/bin/libbreakgen*.so
95 %{_desktopdir}/%{name}.desktop
96 %{_pixmapsdir}/%{name}.png
97 %{_pixmapsdir}/%{name}.svg