- let target_of mafile =
- let _,baseuri,_,_ = Librarian.baseuri_of_script mafile in
+ let root_of opts s =
+ try
+ let include_paths = get_include_paths opts in
+ let root,_,_,_ = Librarian.baseuri_of_script ~include_paths s in
+ Some root
+ with Librarian.NoRootFor x -> None
+ ;;
+
+ let target_of opts mafile =
+ let include_paths = get_include_paths opts in
+ let _,baseuri,_,_ = Librarian.baseuri_of_script ~include_paths mafile in