Bug#943706: opencv: delete static build dir to save lots of space during build
Samuel Thibault
sthibault at debian.org
Sun Jan 5 20:29:20 GMT 2020
Samuel Thibault, le dim. 05 janv. 2020 20:34:46 +0100, a ecrit:
> At least, we could avoid uselessly building the unused static version
> with the attached change. That'll reduce disk usage from tens of
> gigabytes down to a few gigabytes, and probably reduce the build time
> a lot as well.
Even better, there is no need to build the test binaries since they are
not installed either and the testsuite is run on the dynamic version
only.
Samuel
-------------- next part --------------
--- debian/rules.original 2020-01-01 19:27:07.000000000 +0000
+++ debian/rules 2020-01-05 20:28:17.000000000 +0000
@@ -52,10 +58,8 @@
CMAKE_FLAGS = \
-GNinja \
-DANT_EXECUTABLE=/usr/bin/ant \
- -DBUILD_EXAMPLES=ON \
-DBUILD_JAVA=ON \
-DBUILD_PROTOBUF=OFF \
- -DBUILD_TESTS=ON \
-DBUILD_PERF_TESTS=OFF \
-DBUILD_opencv_dnn=ON \
-DBUILD_opencv_dnn_modern=ON \
@@ -123,11 +126,15 @@
# dynamicly linked
dh_auto_configure -B $(BUILDDIR) \
-- $(CMAKE_FLAGS) \
+ -DBUILD_EXAMPLES=ON \
+ -DBUILD_TESTS=ON \
-DCMAKE_SHARED_LINKER_FLAGS_RELEASE="$(LDFLAGS)" \
-DBUILD_SHARED_LIBS=ON -DBUILD_DOCS=ON
# statically linked
dh_auto_configure -B $(BUILDDIR)-static \
-- $(CMAKE_FLAGS) \
+ -DBUILD_EXAMPLES=OFF \
+ -DBUILD_TESTS=OFF \
-DBUILD_SHARED_LIBS=OFF -DBUILD_DOCS=OFF
override_dh_auto_build:
More information about the debian-science-maintainers
mailing list