[llvm] r224977 - [OCaml] [cmake] Use LLVM_LIBRARY_DIR instead of LLVM_LIBRARY_OUTPUT_INTDIR.

Peter Zotov whitequark at whitequark.org
Mon Dec 29 19:24:08 PST 2014


Author: whitequark
Date: Mon Dec 29 21:24:07 2014
New Revision: 224977

URL: http://llvm.org/viewvc/llvm-project?rev=224977&view=rev
Log:
[OCaml] [cmake] Use LLVM_LIBRARY_DIR instead of LLVM_LIBRARY_OUTPUT_INTDIR.

The latter variable is internal.

Original patch by Ramkumar Ramachandra <artagnon at gmail.com>

Modified:
    llvm/trunk/bindings/ocaml/backends/CMakeLists.txt
    llvm/trunk/bindings/ocaml/llvm/CMakeLists.txt
    llvm/trunk/cmake/modules/AddOCaml.cmake

Modified: llvm/trunk/bindings/ocaml/backends/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/bindings/ocaml/backends/CMakeLists.txt?rev=224977&r1=224976&r2=224977&view=diff
==============================================================================
--- llvm/trunk/bindings/ocaml/backends/CMakeLists.txt (original)
+++ llvm/trunk/bindings/ocaml/backends/CMakeLists.txt Mon Dec 29 21:24:07 2014
@@ -20,8 +20,8 @@ foreach(TARGET ${LLVM_TARGETS_TO_BUILD})
 
   configure_file(
     "${CMAKE_CURRENT_SOURCE_DIR}/META.llvm_backend.in"
-    "${LLVM_LIBRARY_OUTPUT_INTDIR}/ocaml/META.llvm_${TARGET}")
+    "${LLVM_LIBRARY_DIR}/ocaml/META.llvm_${TARGET}")
 
-  install(FILES "${LLVM_LIBRARY_OUTPUT_INTDIR}/ocaml/META.llvm_${TARGET}"
+  install(FILES "${LLVM_LIBRARY_DIR}/ocaml/META.llvm_${TARGET}"
           DESTINATION lib/ocaml)
 endforeach()

Modified: llvm/trunk/bindings/ocaml/llvm/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/bindings/ocaml/llvm/CMakeLists.txt?rev=224977&r1=224976&r2=224977&view=diff
==============================================================================
--- llvm/trunk/bindings/ocaml/llvm/CMakeLists.txt (original)
+++ llvm/trunk/bindings/ocaml/llvm/CMakeLists.txt Mon Dec 29 21:24:07 2014
@@ -5,7 +5,7 @@ add_ocaml_library(llvm
 
 configure_file(
   "${CMAKE_CURRENT_SOURCE_DIR}/META.llvm.in"
-  "${LLVM_LIBRARY_OUTPUT_INTDIR}/ocaml/META.llvm")
+  "${LLVM_LIBRARY_DIR}/ocaml/META.llvm")
 
-install(FILES "${LLVM_LIBRARY_OUTPUT_INTDIR}/ocaml/META.llvm"
+install(FILES "${LLVM_LIBRARY_DIR}/ocaml/META.llvm"
         DESTINATION lib/ocaml)

Modified: llvm/trunk/cmake/modules/AddOCaml.cmake
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/cmake/modules/AddOCaml.cmake?rev=224977&r1=224976&r2=224977&view=diff
==============================================================================
--- llvm/trunk/cmake/modules/AddOCaml.cmake (original)
+++ llvm/trunk/cmake/modules/AddOCaml.cmake Mon Dec 29 21:24:07 2014
@@ -52,7 +52,7 @@ function(add_ocaml_library name)
          "${bin}/${name}${CMAKE_STATIC_LIBRARY_SUFFIX}")
   endif()
 
-  set(ocaml_flags "-lstdc++" "-ldopt" "-L${LLVM_LIBRARY_OUTPUT_INTDIR}"
+  set(ocaml_flags "-lstdc++" "-ldopt" "-L${LLVM_LIBRARY_DIR}"
                   ${ocaml_pkgs})
 
   foreach( ocaml_dep ${ARG_OCAMLDEP} )
@@ -144,7 +144,7 @@ function(add_ocaml_library name)
     OUTPUT "${bin}/${name}.odoc"
     COMMAND "${OCAMLFIND}" "ocamldoc"
             "-I" "${bin}"
-            "-I" "${LLVM_LIBRARY_OUTPUT_INTDIR}/ocaml/"
+            "-I" "${LLVM_LIBRARY_DIR}/ocaml/"
             "-dump" "${bin}/${name}.odoc"
             ${ocaml_pkgs} ${ocaml_inputs}
     DEPENDS ${ocaml_inputs}
@@ -192,7 +192,7 @@ function(add_ocaml_library name)
     get_filename_component(filename "${install_file}" NAME)
     add_custom_command(TARGET "ocaml_${name}" POST_BUILD
       COMMAND "${CMAKE_COMMAND}" "-E" "copy" "${install_file}"
-                                             "${LLVM_LIBRARY_OUTPUT_INTDIR}/ocaml/"
+                                             "${LLVM_LIBRARY_DIR}/ocaml/"
       COMMENT "Copying OCaml library component ${filename} to intermediate area"
       VERBATIM)
   endforeach()





More information about the llvm-commits mailing list