<div dir="ltr"><div>David,</div><div><br></div>Thanks a lot! Confirmed that the lit.cfg problem is fixed.<div><br></div><div>-Jiangning</div></div><div class="gmail_extra"><br><div class="gmail_quote">2014-11-04 13:54 GMT+08:00 David Majnemer <span dir="ltr"><<a href="mailto:david.majnemer@gmail.com" target="_blank">david.majnemer@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: majnemer<br>
Date: Mon Nov  3 23:54:50 2014<br>
New Revision: 221242<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=221242&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=221242&view=rev</a><br>
Log:<br>
test: Restore llvm-lit (at least for my machine)<br>
<br>
r221137 feeds None into os.path.join which is not valid.<br>
<br>
Modified:<br>
    llvm/trunk/test/lit.cfg<br>
<br>
Modified: llvm/trunk/test/lit.cfg<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/lit.cfg?rev=221242&r1=221241&r2=221242&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/lit.cfg?rev=221242&r1=221241&r2=221242&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/lit.cfg (original)<br>
+++ llvm/trunk/test/lit.cfg Mon Nov  3 23:54:50 2014<br>
@@ -97,22 +97,25 @@ for symbolizer in ['ASAN_SYMBOLIZER_PATH<br>
<br>
 # Set up OCAMLPATH to include newly built OCaml libraries.<br>
 llvm_lib_dir = getattr(config, 'llvm_lib_dir', None)<br>
-if not llvm_lib_dir:<br>
-    llvm_lib_dir = os.path.join(getattr(config, 'llvm_obj_root', None), 'lib')<br>
+if llvm_lib_dir is None:<br>
+    if llvm_obj_root is not None:<br>
+        llvm_lib_dir = os.path.join(llvm_obj_root, 'lib')<br>
<br>
-llvm_ocaml_lib = os.path.join(llvm_lib_dir, 'ocaml')<br>
-if 'OCAMLPATH' in os.environ:<br>
-    ocamlpath = os.path.pathsep.join((llvm_ocaml_lib, os.environ['OCAMLPATH']))<br>
-    config.environment['OCAMLPATH'] = ocamlpath<br>
-else:<br>
-    config.environment['OCAMLPATH'] = llvm_ocaml_lib<br>
+if llvm_lib_dir is not None:<br>
+    llvm_ocaml_lib = os.path.join(llvm_lib_dir, 'ocaml')<br>
+    if llvm_ocaml_lib is not None:<br>
+        if 'OCAMLPATH' in os.environ:<br>
+            ocamlpath = os.path.pathsep.join((llvm_ocaml_lib, os.environ['OCAMLPATH']))<br>
+            config.environment['OCAMLPATH'] = ocamlpath<br>
+        else:<br>
+            config.environment['OCAMLPATH'] = llvm_ocaml_lib<br>
<br>
-if 'CAML_LD_LIBRARY_PATH' in os.environ:<br>
-    caml_ld_library_path = os.path.pathsep.join((llvm_ocaml_lib,<br>
-                                os.environ['CAML_LD_LIBRARY_PATH']))<br>
-    config.environment['CAML_LD_LIBRARY_PATH'] = caml_ld_library_path<br>
-else:<br>
-    config.environment['CAML_LD_LIBRARY_PATH'] = llvm_ocaml_lib<br>
+        if 'CAML_LD_LIBRARY_PATH' in os.environ:<br>
+            caml_ld_library_path = os.path.pathsep.join((llvm_ocaml_lib,<br>
+                                        os.environ['CAML_LD_LIBRARY_PATH']))<br>
+            config.environment['CAML_LD_LIBRARY_PATH'] = caml_ld_library_path<br>
+        else:<br>
+            config.environment['CAML_LD_LIBRARY_PATH'] = llvm_ocaml_lib<br>
<br>
 # Set up OCAMLRUNPARAM to enable backtraces in OCaml tests.<br>
 config.environment['OCAMLRUNPARAM'] = 'b'<br>
<br>
<br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
</blockquote></div><br></div>