freecad/freecad.spec

109 lines
2.9 KiB
RPMSpec
Raw Normal View History

2014-06-20 11:23:26 +04:00
Summary: FreeCAD is a general purpose 3D CAD modeler
Name: freecad
Version: 0.13.1830
2014-07-25 16:35:44 +04:00
Release: 3
2014-06-20 11:23:26 +04:00
License: GPL and LGPL
2013-08-02 11:39:04 +04:00
Group: Graphics
Url: http://free-cad.sourceforge.net/
Source0: http://dfn.dl.sourceforge.net/sourceforge/free-cad/freecad-%{version}.tar.gz
2014-06-20 11:23:26 +04:00
Source1: freecad.desktop
Source2: freecad.1
2013-08-02 11:39:04 +04:00
Source3: %{name}.rpmlintrc
2014-06-20 17:54:35 +04:00
# Patch to build with non-backward compatible change in QT4.
2014-06-20 18:31:10 +04:00
Patch1: freecad-0.13-qt4_cmake.patch
2014-06-20 17:54:35 +04:00
2014-06-20 18:52:41 +11:00
BuildRequires: cmake
BuildRequires: eigen3
BuildRequires: gcc-gfortran
BuildRequires: python-matplotlib
BuildRequires: boost-devel
BuildRequires: opencascade-devel
BuildRequires: qt4-devel
2014-06-20 18:55:36 +04:00
BuildRequires: pkgconfig(SoQt)
2014-06-20 18:52:41 +11:00
BuildRequires: pkgconfig(Coin)
BuildRequires: pkgconfig(gstreamer-0.10)
BuildRequires: pkgconfig(ode)
BuildRequires: pkgconfig(opencv)
BuildRequires: pkgconfig(python)
BuildRequires: pkgconfig(xerces-c)
%description
FreeCAD will be a general purpose 3D CAD modeler.
2014-06-20 18:52:41 +11:00
The development will be completely Open Source. As with many modern 3D CAD
modelers it will have a 2D component in order to extract design detail from
the 3D model to create 2D production drawings, although 2D (e.g. AutoCAD LT)
is not the focus, neither are animation and organic shapes (e.g. Maya,
3D StudioMAX and Cinema 4D).
%files
%doc ChangeLog.txt copying.lib data/License.txt build/doc/*
%{_bindir}/*
%{_datadir}/applications/%{name}.desktop
%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg
%{_libdir}/%{name}/bin/
%{_libdir}/%{name}/lib/
%{_libdir}/%{name}/Mod/
%{_datadir}/%{name}/
%{_mandir}/man1/*.1*
#----------------------------------------------------------------------------
%package devel
2014-06-20 18:52:41 +11:00
Summary: Devel package for %{name}
Requires: %{name} = %{version}
Group: Development/C++
%description devel
2014-06-20 18:52:41 +11:00
Development files for FreeCAD.
%files devel
%{_libdir}/%{name}/include/*
#----------------------------------------------------------------------------
%prep
2014-06-20 18:52:41 +11:00
%setup -q
2014-06-20 17:54:35 +04:00
%apply_patches
%build
%define Werror_cflags %nil
2014-06-20 18:52:41 +11:00
%cmake_qt4 \
-DCMAKE_INSTALL_PREFIX=%{_libdir}/%{name} \
-DCMAKE_INSTALL_DATADIR=%{_datadir}/%{name} \
-DCMAKE_INSTALL_DOCDIR=%{_docdir}/%{name} \
-DCMAKE_INSTALL_INCLUDEDIR=%{_includedir} \
-DRESOURCEDIR=%{_libdir}/freecad
%make
%install
%makeinstall_std -C build
2013-08-01 17:54:09 +04:00
# Symlink binaries to /usr/bin
mkdir -p %{buildroot}%{_bindir}
pushd %{buildroot}%{_bindir}
ln -s ../%{_lib}/freecad/bin/FreeCAD .
ln -s ../%{_lib}/freecad/bin/FreeCADCmd .
popd
2013-08-02 11:39:04 +04:00
# Install desktop file
desktop-file-install \
--dir=%{buildroot}%{_datadir}/applications %{SOURCE1}
sed -i 's,@lib@,%{_lib},g' %{buildroot}%{_datadir}/applications/%{name}.desktop
# Install desktop icon
install -pD -m 0644 src/Gui/Icons/%{name}.svg \
%{buildroot}%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg
# Install man page
2013-08-02 12:13:55 +04:00
install -pD -m 0644 %{SOURCE2} \
2013-08-02 11:39:04 +04:00
%{buildroot}%{_mandir}/man1/%{name}.1
# Symlink manpage to other binary names
pushd %{buildroot}%{_mandir}/man1
ln -sf %{name}.1.gz FreeCAD.1.gz.
ln -sf %{name}.1.gz FreeCADCmd.1.gz
popd