Browse Source

Revert "add the local directory to the library search path for C/C++ block compilation"

This reverts commit 4202665f5b93feb2af87c50a260d5cfc1455ca73.

The buffer file name is not always available (e.g., during export), so
it should not be relied upon, rather a header argument should be used.
Eric Schulte 13 years ago
parent
commit
18c68c13aa
1 changed files with 2 additions and 3 deletions
  1. 2 3
      lisp/ob-C.el

+ 2 - 3
lisp/ob-C.el

@@ -96,15 +96,14 @@ or `org-babel-execute:C++'."
 	  (progn
 	    (with-temp-file tmp-src-file (insert full-body))
 	    (org-babel-eval
-	     (format "%s -o %s %s %s -I \"%s\""
+	     (format "%s -o %s %s %s"
 		     (cond
 		      ((equal org-babel-c-variant 'c) org-babel-C-compiler)
 		      ((equal org-babel-c-variant 'cpp) org-babel-C++-compiler))
 		     (org-babel-process-file-name tmp-bin-file)
 		     (mapconcat 'identity
 				(if (listp flags) flags (list flags)) " ")
-		     (org-babel-process-file-name tmp-src-file)
-		     (file-name-directory (buffer-file-name))) ""))))
+		     (org-babel-process-file-name tmp-src-file)) ""))))
     ((lambda (results)
        (org-babel-reassemble-table
 	(if (member "vector" (cdr (assoc :result-params params)))