1/*****************************************************************************
    2 * This file is part of the Prolog Development Tool (PDT)
    3 * 
    4 * Author: Andreas Becker
    5 * WWW: http://sewiki.iai.uni-bonn.de/research/pdt/start
    6 * Mail: pdt@lists.iai.uni-bonn.de
    7 * Copyright (C): 2012, CS Dept. III, University of Bonn
    8 * 
    9 * All rights reserved. This program is  made available under the terms
   10 * of the Eclipse Public License v1.0 which accompanies this distribution,
   11 * and is available at http://www.eclipse.org/legal/epl-v10.html
   12 * 
   13 ****************************************************************************/
   14
   15:- multifile(logtalk_library_path/2).   16:- dynamic(logtalk_library_path/2).   17logtalk_library_path(prolog_connector_pl_lgt, Library) :-
   18	absolute_file_name(prolog_connector_pl('lgt/loader.pl'), FilePath),
   19	file_directory_name(FilePath,Directory),
   20	atom_concat(Directory, '/', Library).
   21
   22load_lgt_reload_adapter :-
   23	(	current_predicate(user:logtalk_load/1)
   24	->	set_logtalk_flag(code_prefix, '.'),
   25		set_logtalk_flag(optimize, off),
   26		set_prolog_flag(optimise, off),
   27		(	current_prolog_flag(logtalk_source_location_data, _)
   28		->	set_prolog_flag(logtalk_source_location_data, true)
   29		;	true
   30		),
   31		logtalk_load([
   32			prolog_connector_pl_lgt(logtalk_reload_adapter)
   33		])
   34	;	true
   35	).
   36	
   37:- initialization( load_lgt_reload_adapter ).