2018-05-22 04:08:47 +03:00
|
|
|
%define oname FreeCAD
|
2016-01-11 21:18:23 +01:00
|
|
|
|
2014-06-20 11:23:26 +04:00
|
|
|
Summary: FreeCAD is a general purpose 3D CAD modeler
|
|
|
|
Name: freecad
|
2024-11-19 20:14:04 +00:00
|
|
|
Version: 1.0.0
|
2018-05-22 04:08:47 +03:00
|
|
|
Release: 1
|
2016-01-11 21:18:23 +01:00
|
|
|
License: GPLv2+ and LGPLv2+
|
|
|
|
Group: Graphics
|
2020-11-26 09:45:23 +03:00
|
|
|
URL: http://www.freecadweb.org/
|
|
|
|
Source0: https://github.com/FreeCAD/FreeCAD/archive/%{version}/%{oname}-%{version}.tar.gz
|
2016-01-11 21:18:23 +01:00
|
|
|
Source1: %{name}.desktop
|
|
|
|
Source2: %{name}.1
|
2013-08-02 11:39:04 +04:00
|
|
|
Source3: %{name}.rpmlintrc
|
2018-05-22 04:08:47 +03:00
|
|
|
BuildRequires: boost-devel >= 1.33.1
|
2014-06-20 18:52:41 +11:00
|
|
|
BuildRequires: cmake
|
2020-01-19 21:40:04 +03:00
|
|
|
BuildRequires: eigen3 >= 3.3.1
|
2014-06-20 18:52:41 +11:00
|
|
|
BuildRequires: gcc-gfortran
|
2016-04-17 21:07:56 +03:00
|
|
|
BuildRequires: libspnav-devel
|
2018-05-22 04:08:47 +03:00
|
|
|
BuildRequires: med-devel
|
2016-01-11 21:18:23 +01:00
|
|
|
BuildRequires: opencascade-devel >= 5.2
|
2018-05-22 04:08:47 +03:00
|
|
|
BuildRequires: openmpi-devel
|
2016-01-11 21:18:23 +01:00
|
|
|
BuildRequires: pkgconfig(Coin) >= 2.4.0
|
2018-05-22 04:08:47 +03:00
|
|
|
BuildRequires: pkgconfig(SoQt) >= 1.2.0
|
2016-01-11 21:18:23 +01:00
|
|
|
BuildRequires: pkgconfig(freetype2)
|
2018-05-22 04:08:47 +03:00
|
|
|
BuildRequires: pkgconfig(glu)
|
2014-06-20 18:52:41 +11:00
|
|
|
BuildRequires: pkgconfig(gstreamer-0.10)
|
2018-05-22 04:08:47 +03:00
|
|
|
BuildRequires: pkgconfig(jsoncpp)
|
2014-06-20 18:52:41 +11:00
|
|
|
BuildRequires: pkgconfig(ode)
|
|
|
|
BuildRequires: pkgconfig(opencv)
|
2018-05-22 04:08:47 +03:00
|
|
|
BuildRequires: pkgconfig(pyside)
|
2016-01-11 21:18:23 +01:00
|
|
|
BuildRequires: pkgconfig(python) >= 2.5
|
2020-01-19 21:40:04 +03:00
|
|
|
BuildRequires: pkgconfig(python3)
|
2014-09-29 10:34:45 +04:00
|
|
|
BuildRequires: pkgconfig(shiboken)
|
2016-01-11 21:18:23 +01:00
|
|
|
BuildRequires: pkgconfig(xerces-c) >= 2.6
|
2018-05-22 04:08:47 +03:00
|
|
|
BuildRequires: pyside-tools
|
|
|
|
BuildRequires: python-matplotlib
|
|
|
|
BuildRequires: python-vtk
|
|
|
|
BuildRequires: qt4-devel
|
|
|
|
BuildRequires: tcl-vtk
|
|
|
|
BuildRequires: tcl-vtk-qt
|
|
|
|
BuildRequires: vtk-devel
|
|
|
|
BuildRequires: vtk-test-suite
|
2020-01-19 21:40:04 +03:00
|
|
|
BuildRequires: swig
|
|
|
|
BuildRequires: boost-devel
|
|
|
|
# Qt5 + Python3
|
|
|
|
BuildRequires: pkgconfig(Qt5Core)
|
|
|
|
BuildRequires: pkgconfig(Qt5OpenGL)
|
|
|
|
BuildRequires: pkgconfig(Qt5WebEngine)
|
|
|
|
BuildRequires: pkgconfig(Qt5XmlPatterns)
|
|
|
|
BuildRequires: pkgconfig(Qt5X11Extras)
|
|
|
|
BuildRequires: pkgconfig(Qt5Xml)
|
|
|
|
BuildRequires: pkgconfig(Qt5PrintSupport)
|
|
|
|
BuildRequires: pkgconfig(Qt5Svg)
|
|
|
|
BuildRequires: pkgconfig(Qt5UiTools)
|
|
|
|
BuildRequires: pkgconfig(Qt5Concurrent)
|
|
|
|
BuildRequires: pkgconfig(Qt5WebKitWidgets)
|
|
|
|
BuildRequires: python3-matplotlib
|
|
|
|
#BuildRequires: python3-pivy
|
|
|
|
BuildRequires: python3-ply
|
|
|
|
BuildRequires: python3-qt5-core
|
|
|
|
#python3-pyside2.qtcore
|
|
|
|
BuildRequires: python3-qt5-gui
|
|
|
|
#python3-pyside2.qtgui
|
|
|
|
BuildRequires: python3-qt5-svg
|
|
|
|
#python3-pyside2.qtsvg
|
|
|
|
BuildRequires: python3-qt5-widgets
|
|
|
|
#python3-pyside2.qtwidgets
|
|
|
|
#BuildRequires: python3-pyside2uic
|
|
|
|
# shiboken2
|
|
|
|
# PySide2
|
|
|
|
# PySide2Tools
|
|
|
|
|
|
|
|
|
2016-09-19 18:18:57 +04:00
|
|
|
Requires: pyside
|
2010-08-08 18:23:07 +00:00
|
|
|
|
|
|
|
%description
|
2016-01-11 21:18:23 +01:00
|
|
|
FreeCAD will be a general purpose parametric 3D CAD modeler. The development
|
|
|
|
is completely Open Source. It is a feature based parametric modeler with a
|
|
|
|
modular software architecture which makes it easy to provide additional
|
|
|
|
functionality without modifying the core system. As with many modern 3D CAD
|
|
|
|
modelers it has many 2D component in order to extract design detail from
|
|
|
|
the 3D model to create 2D production drawings, but direct 2D drawing (e.g.
|
|
|
|
AutoCAD LT) is not the focus, neither are animation and organic shapes (e.g.
|
|
|
|
Maya, 3D StudioMAX, Blender and Cinema 4D).
|
2014-06-20 18:52:41 +11:00
|
|
|
|
|
|
|
%files
|
2020-01-19 21:40:04 +03:00
|
|
|
%doc ChangeLog.txt LICENSE data/License.txt build/doc/*
|
2014-06-20 18:52:41 +11:00
|
|
|
%{_bindir}/*
|
2018-05-22 04:08:47 +03:00
|
|
|
%{_datadir}/%{name}/
|
2016-01-11 21:18:23 +01:00
|
|
|
%{_datadir}/applications/%{name}.desktop
|
|
|
|
%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg
|
2018-05-22 04:08:47 +03:00
|
|
|
%{_libdir}/%{name}/*.so
|
|
|
|
%{_libdir}/%{name}/Mod/
|
|
|
|
%{_libdir}/%{name}/bin/
|
2018-05-22 14:32:18 +03:00
|
|
|
%{_libdir}/%{name}/Ext/
|
2020-01-19 21:40:04 +03:00
|
|
|
%{_libdir}/%{name}/share/
|
2014-06-20 18:52:41 +11:00
|
|
|
%{_mandir}/man1/*.1*
|
|
|
|
|
|
|
|
#----------------------------------------------------------------------------
|
2010-08-08 18:23:07 +00:00
|
|
|
|
|
|
|
%package devel
|
2014-06-20 18:52:41 +11:00
|
|
|
Summary: Devel package for %{name}
|
2018-05-22 04:08:47 +03:00
|
|
|
Requires: %{name} = %{EVRD}
|
2014-06-20 18:52:41 +11:00
|
|
|
Group: Development/C++
|
2010-08-08 18:23:07 +00:00
|
|
|
|
|
|
|
%description devel
|
2014-06-20 18:52:41 +11:00
|
|
|
Development files for FreeCAD.
|
|
|
|
|
|
|
|
%files devel
|
2020-01-19 21:40:04 +03:00
|
|
|
%doc ChangeLog.txt LICENSE
|
2016-01-11 21:18:23 +01:00
|
|
|
%{_libdir}/%{name}/include/
|
2014-06-20 18:52:41 +11:00
|
|
|
|
|
|
|
#----------------------------------------------------------------------------
|
2010-08-08 18:23:07 +00:00
|
|
|
|
|
|
|
%prep
|
2016-01-11 21:18:23 +01:00
|
|
|
%setup -qn %{oname}-%{version}
|
|
|
|
#%%apply_patches
|
|
|
|
|
|
|
|
# Fix bogus file perms
|
|
|
|
find ./src -name "*.py*" |xargs chmod 755
|
|
|
|
find ./src -name "*.h*" |xargs chmod 644
|
|
|
|
find ./src -name "*.cpp*" |xargs chmod 644
|
|
|
|
|
2010-08-08 18:23:07 +00:00
|
|
|
%build
|
2018-05-22 04:08:47 +03:00
|
|
|
#%%define Werror_cflags %%{nil}
|
2020-01-19 21:40:04 +03:00
|
|
|
#cmake_qt4 \
|
|
|
|
#cmake_qt5 \
|
|
|
|
# -DBUILD_QT5=ON \
|
|
|
|
# -DPYTHON_EXECUTABLE=/usr/bin/python3 \
|
|
|
|
%cmake_qt4 \
|
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
2016-01-11 21:18:23 +01:00
|
|
|
-DCMAKE_INSTALL_PREFIX=%{_libdir}/%{name} \
|
|
|
|
-DCMAKE_INSTALL_INCLUDEDIR=%{_libdir}/%{name}/include \
|
2014-06-20 18:52:41 +11:00
|
|
|
-DCMAKE_INSTALL_DATADIR=%{_datadir}/%{name} \
|
|
|
|
-DCMAKE_INSTALL_DOCDIR=%{_docdir}/%{name} \
|
2016-01-11 21:18:23 +01:00
|
|
|
-DCMAKE_INSTALL_LIBDIR=%{_libdir}/%{name} \
|
2020-01-19 21:40:04 +03:00
|
|
|
-DRESOURCEDIR=%{_datadir}/%{name}
|
2010-08-08 18:23:07 +00:00
|
|
|
%make
|
|
|
|
|
|
|
|
%install
|
|
|
|
%makeinstall_std -C build
|
|
|
|
|
2013-08-01 17:54:09 +04:00
|
|
|
# Symlink binaries to /usr/bin
|
2016-01-11 21:18:23 +01:00
|
|
|
mkdir -p %{buildroot}%{_bindir}
|
|
|
|
pushd %{buildroot}%{_bindir}
|
|
|
|
ln -s ../%{_lib}/freecad/bin/FreeCAD .
|
|
|
|
ln -s ../%{_lib}/freecad/bin/FreeCADCmd .
|
|
|
|
popd
|
2013-08-01 17:54:09 +04:00
|
|
|
|
2016-01-11 21:18:23 +01:00
|
|
|
# Fix bogus perms
|
|
|
|
chmod +x %{buildroot}%{_libdir}/%{name}/Mod/PartDesign/Scripts/*.py
|
2013-08-02 11:39:04 +04:00
|
|
|
|
2016-01-11 21:18:23 +01:00
|
|
|
# Install and fix .desktop file
|
|
|
|
desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{SOURCE1}
|
2013-08-02 11:39:04 +04:00
|
|
|
sed -i 's,@lib@,%{_lib},g' %{buildroot}%{_datadir}/applications/%{name}.desktop
|
|
|
|
|
|
|
|
# Install desktop icon
|
|
|
|
install -pD -m 0644 src/Gui/Icons/%{name}.svg \
|
2018-05-22 04:08:47 +03:00
|
|
|
%{buildroot}%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg
|
2013-08-02 11:39:04 +04:00
|
|
|
|
2016-01-11 21:18:23 +01:00
|
|
|
# Install man page
|
|
|
|
install -pD -m 0644 %{SOURCE2} %{buildroot}%{_mandir}/man1/%{name}.1
|
2013-08-02 11:39:04 +04:00
|
|
|
# Symlink manpage to other binary names
|
|
|
|
pushd %{buildroot}%{_mandir}/man1
|
2018-05-22 04:08:47 +03:00
|
|
|
ln -sf %{name}.1.gz FreeCAD.1.gz.
|
|
|
|
ln -sf %{name}.1.gz FreeCADCmd.1.gz
|
2013-08-02 11:39:04 +04:00
|
|
|
popd
|
|
|
|
|
2016-01-11 21:18:23 +01:00
|
|
|
# FIXME: Apparently there are no more include files to install.
|
|
|
|
# For now keep the devel package and manually create the needed (empty) dir
|
2016-04-17 15:30:43 +03:00
|
|
|
mkdir -p %{buildroot}%{_libdir}/%{name}/include
|