In cmake build system, shared libraries are being built in source directory. It is better to set a common place to maintain built libraries. In addition, test bot uploads libraries with test result. Thus, I need a common place for all libraries in order to upload all libraries.
Created attachment 125757 [details] Patch
CC'ing Daniel, Patrick and Kubo.
Created attachment 125765 [details] Patch
Comment on attachment 125765 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=125765&action=review > Source/cmake/WebKitFS.cmake:4 > +FILE(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/libs) AFAIK this isn't necessary. CMake takes care of creating directories when needed. > CMakeLists.txt:45 > +SET(LIBRARY_OUTPUT_PATH "${CMAKE_BINARY_DIR}/libs") Why "libs", isn't "lib" more common for such a directory (like "bin" is more common than "Programs")?
(In reply to comment #4) > (From update of attachment 125765 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=125765&action=review > > > Source/cmake/WebKitFS.cmake:4 > > +FILE(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/libs) > > AFAIK this isn't necessary. CMake takes care of creating directories when needed. Ok, I fix it. Frankly, above code is not necessary. I added it to create directory more correctly as *Programs*. > > CMakeLists.txt:45 > > +SET(LIBRARY_OUTPUT_PATH "${CMAKE_BINARY_DIR}/libs") > > Why "libs", isn't "lib" more common for such a directory (like "bin" is more common than "Programs")? QT port is using *bin* and *lib*. By comparison, GTK port is using *Programs* and *.libs*. I think we have to get agreement from port maintainers(Wince, Blackberry and EFL). I agree. :-)
(In reply to comment #5) > (In reply to comment #4) > > Why "libs", isn't "lib" more common for such a directory (like "bin" is more common than "Programs")? > > QT port is using *bin* and *lib*. By comparison, GTK port is using *Programs* and *.libs*. I think we have to get agreement from port maintainers(Wince, Blackberry and EFL). I agree. :-) There is also the common "/usr/bin" and "/usr/lib".
Created attachment 125798 [details] Patch
New patch is submitted. I set bin and lib directory for executable and library. Daniel reviews this patch, I think blackberry port also agrees with this change.
Comment on attachment 125798 [details] Patch IMHO you should use sth. like: SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin) SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) in the root CMakeLists.txt, instead of adding this to the different executeable names.
(In reply to comment #9) > (From update of attachment 125798 [details]) > IMHO you should use sth. like: > SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) > SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin) > SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) > in the root CMakeLists.txt, instead of adding this to the different executeable names. When we set CMAKE_ARCHIVE_OUTPUT_DIRECTORY, static libraries are also moved to lib directory. I think it is better to move shared libraries to lib directory only. Why don't we use below setting ? SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
Created attachment 125813 [details] Patch
(In reply to comment #10) > (In reply to comment #9) > > (From update of attachment 125798 [details] [details]) > > IMHO you should use sth. like: > > SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) > > SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin) > > SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) > > in the root CMakeLists.txt, instead of adding this to the different executeable names. > > > When we set CMAKE_ARCHIVE_OUTPUT_DIRECTORY, static libraries are also moved to lib directory. I think it is better to move shared libraries to lib directory only. > > Why don't we use below setting ? > > SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) > SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin) It's ok for me too. I only want to avoid the "'Programs/' prefix" on the different targets. ;-)
Comment on attachment 125813 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=125813&action=review > CMakeLists.txt:46 > +SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) > +SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin) I don't have a CMake build at the moment. I assume that these directories are created by CMake in the directory CMAKE_BINARY_DIR.
(In reply to comment #13) > (From update of attachment 125813 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=125813&action=review > > > CMakeLists.txt:46 > > +SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) > > +SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin) > > I don't have a CMake build at the moment. I assume that these directories are created by CMake in the directory CMAKE_BINARY_DIR. Yes, right. *.so files are created in CMAKE_BINARY_DIR/lib and excutables are created in CMAKE_BINARY_DIR/bin.
Comment on attachment 125813 [details] Patch Clearing flags on attachment: 125813 Committed r107020: <http://trac.webkit.org/changeset/107020>
All reviewed patches have been landed. Closing bug.