Packaging: add a spec file for Tizen build tizen
authorTae-Young Chung <ty83.chung@samsung.com>
Wed, 28 Mar 2018 12:31:17 +0000 (21:31 +0900)
committerWook Song <wook16.song@samsung.com>
Mon, 10 Feb 2020 10:57:30 +0000 (19:57 +0900)
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
packaging/caffe.manifest [new file with mode: 0644]
packaging/caffe.spec [new file with mode: 0644]

diff --git a/packaging/caffe.manifest b/packaging/caffe.manifest
new file mode 100644 (file)
index 0000000..97e8c31
--- /dev/null
@@ -0,0 +1,5 @@
+<manifest>
+       <request>
+               <domain name="_"/>
+       </request>
+</manifest>
diff --git a/packaging/caffe.spec b/packaging/caffe.spec
new file mode 100644 (file)
index 0000000..909c14c
--- /dev/null
@@ -0,0 +1,77 @@
+Name:       caffe
+Summary:    Caffe is a deep learning framework made with expression, speed, and modularity in mind
+Version:    1.0
+Release:    0
+Group:      Machine Learning Framework/Libraries
+License:    BSD-2-Clause
+Source0:    %{name}-%{version}.tar.gz
+Source1001: %{name}.manifest
+BuildRequires: cmake
+BuildRequires: boost-devel
+BuildRequires: glog-devel
+BuildRequires: gflags-devel
+BuildRequires: hdf5-devel
+BuildRequires: openblas-devel
+BuildRequires: lmdb-devel
+BuildRequires: protobuf-devel
+BuildRequires: pkgconfig(opencv)
+#BuildRequires: protobuf-devel >= 3.1.0
+#BuildRequires: pkgconfig(opencv) >= 3.4.0
+
+%description
+Caffe is a deep learning framework made with expression, speed, and modularity in mind 
+%package devel
+Summary:  Caffe is a deep learning framework made with expression, speed, and modularity in mind
+Group:    multimedia
+Requires: %{name} = %{version}-%{release}
+
+
+%description devel
+%devel_desc
+
+%prep
+%setup -q
+cp %{SOURCE1001} .
+
+
+%build
+mkdir build
+cd build
+%cmake .. \
+    -DCPU_ONLY=ON \
+    -DBUILD_SHARED_LIBS=ON \
+    -DBUILD_python=OFF \
+    -DBUILD_docs=OFF \
+    -DBUILD_python_layer=OFF \
+    -DBUILD_matlab=OFF \
+    -DALLOW_LMDB_NOLOCK=OFF \
+    -DUSE_NCCL=OFF \
+    -DUSE_LEVELDB=OFF \
+    -DUSE_LMDB=OFF \
+    -DUSE_OPENCV=ON \
+    -DUSE_OPENMP=OFF \
+    -DBLAS=Open
+
+make %{?jobs:-j%jobs}
+
+
+%install
+rm -rf %{buildroot}
+cd build
+%make_install
+
+
+%post
+/sbin/ldconfig
+
+%postun -p /sbin/ldconfig
+
+
+%files
+%{_libdir}/*.so*
+%{_bindir}/*
+
+%files devel
+%{_includedir}/*
+/usr/python/caffe/*
+/usr/share/Caffe/*