dcoughlin added a comment.

Thanks for adding `bear_get_environment()` to handle the environment weirdness 
on Darwin.


================
Comment at: tools/scan-build-py/libscanbuild/intercept.py:146
@@ +145,3 @@
+        })
+    elif sys.platform == 'darwin':
+        logging.debug('intercept gonna preload libear on OSX')
----------------
Can you change this to default to compiler-wrapper interposition on Darwin with 
a command-line flag to force library-based interposition?

Library-based interposition will fail silently if SIP is enabled, so this 
should be detected when that flag is passed so the user is informed. You can 
detect whether SIP is enabled on Darwin by checking whether (1) there is a 
binary called 'csrutil' in the path and, if so, (2) whether the output of 
executing 'csrutil status' contains 'System Integrity Protection status: 
enabled'.




http://reviews.llvm.org/D9600



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to