[FIXED] Patch #2125 CMake shouldn't generate Version.in for release tarballs

Having trouble installing or compiling FreeCAD? Get help here.
User avatar
Kunda1
Posts: 7065
Joined: Thu Jan 05, 2017 9:03 pm

[FIXED] Patch #2125 CMake shouldn't generate Version.in for release tarballs

Postby Kunda1 » Tue Jan 10, 2017 5:45 pm

The ticket issue #2125 contains the below diff. Can anyone weigh in if there is a necessity for it?

Code: Select all

diff -Naur freecad-0.14.3702.orig/src/CMakeLists.txt freecad-0.14.3702/src/CMakeLists.txt
--- freecad-0.14.3702.orig/src/CMakeLists.txt 2014-07-13 10:33:02.000000000 -0500
+++ freecad-0.14.3702/src/CMakeLists.txt 2015-05-28 11:08:21.169188616 -0500
@@ -1,5 +1,7 @@
-
-add_subdirectory(Build)
+# Do not generate a new Version.h if the source is a release tarball.
+if(NOT EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/Build/Version.h)
+ add_subdirectory(Build)
+endif()
 add_subdirectory(3rdParty)
 add_subdirectory(Base)
 add_subdirectory(App)
Last edited by Kunda1 on Thu Jan 12, 2017 2:50 pm, edited 1 time in total.
Want to contribute back to FC? Checkout:
#lowhangingfruit | Use the Source, Luke. | How to Help FreeCAD | How to report FC bugs and features
wmayer
Site Admin
Posts: 15484
Joined: Thu Feb 19, 2009 10:32 am

Re: Bug #2125 CMake shouldn't generate Version.in for release tarballs

Postby wmayer » Tue Jan 10, 2017 6:32 pm

Looks lie it's a valid one. I will assign it to me.