Mentions légales du service

Skip to content
Snippets Groups Projects
Commit 1dc88bf0 authored by POGODALLA Sylvain's avatar POGODALLA Sylvain
Browse files

Take into account jbuilder replacement by dune in opam and fixes #14

parent f738eb30
Branches
No related tags found
No related merge requests found
......@@ -28,19 +28,19 @@ TAR_RELEASE = $(RELEASE)
ACGtk_DIR = $(shell basename `pwd`)
clean:
jbuilder clean
dune clean
find . -name "*~" -exec rm -f {} \;
set_log_level:
# find . -name "jbuild" -exec sed -i -e 's/-level \([^ ]*\)/-level TRACE/' {} \;
find . -name "jbuild" -exec sed -i -e 's/-level \([^ ]*\)/-level NONE/' {} \;
# find . -name "dune" -exec sed -i -e 's/-level \([^ ]*\)/-level TRACE/' {} \;
find . -name "dune" -exec sed -i -e 's/-level \([^ ]*\)/-level NONE/' {} \;
install:
jbuilder install
dune install
uninstall:
jbuilder uninstall
dune uninstall
tar:
if test -d ../$(TAR_RELEASE) ; then rm ../$(TAR_RELEASE) ; fi
......
opam-version: "1.2"
maintainer: "sylvain.pogodalla@inria.fr"
build: [
["jbuilder" "subst"] {pinned}
# remove the -p to also build the local libraries: conflict with the
# fact that some libraries are also part of the acgtkLib package
# ["jbuilder" "build" "-p" name "-j" jobs]
["jbuilder" "build" "-j" jobs]
]
install: ["jbuilder" "install"]
depends: [
"jbuilder" {build}
"dypgen"
"camlp4"
"bolt"
"ANSITerminal"
"cairo2"
"yojson"
"easy-format"
"ocf"
]
available: [ ocaml-version >= "4.03.0" ]
dev-repo: "https://gitlab.inria.fr/ACG/dev/ACGtk.git"
homepage: "http://acg.gforge.inria.fr/"
license: "CeCILL"
authors: ["Sylvain Pogodalla"]
bug-reports: "sylvain.pogodalla@inria.fr"
opam-package/opam
\ No newline at end of file
......@@ -192,7 +192,6 @@ lib: [
]
doc: [
"_build/install/default/doc/acgtkLib/README.md"
"_build/install/default/doc/acgtkLib/README.html~"
"_build/install/default/doc/acgtkLib/README-opam"
"_build/install/default/doc/acgtkLib/README"
"_build/install/default/doc/acgtkLib/LICENSE.md"
......
......@@ -2,12 +2,12 @@ opam-version: "1.2"
maintainer: "sylvain.pogodalla@inria.fr"
build: [
["jbuilder" "subst"] {pinned}
["jbuilder" "build" "-p" name "-j" jobs]
["dune" "subst"] {pinned}
["dune" "build" "-p" name "-j" jobs]
]
depends: [
"jbuilder" {build}
"dune" {build}
"dypgen"
"camlp4"
"bolt"
......
dune 0 → 100644
;; -*-lisp-*-
(env
(release
(flags (:standard -w -58)))
(dev
(flags (:standard -w +42))))
(lang dune 1.0)
\ No newline at end of file
(lang dune 1.0)
(profile release)
\ No newline at end of file
;; -*-lisp-*-
(install
(package acgtk)
(section share_root)
(files (acg.el as emacs/site-lisp/acg.el))
)
;; -*-lisp-*-
(jbuild_version 1)
(install
(
(package acgtk)
(section share_root)
(files ((acg.el as emacs/site-lisp/acg.el)))))
;; -*-lisp-*-
(install
(package acgtk)
(section share)
(files
(anbncndn.acg as examples/anbncndn.acg)
(cfg.acg as examples/cfg.acg)
(config.json as examples/config.json)
(demo-script as examples/demo-script)
(Jean-regarde-telescope.acg as examples/Jean-regarde-telescope.acg)
(MK-lecture-example.acg as examples/MK-lecture-example.acg)
(montague.acg as examples/montague.acg)
(montague-fr.acg as examples/montague-fr.acg)
(montague-script as examples/montague-script)
(README as examples/README)
(README.md as examples/README.md)
(strings.acg as examples/strings.acg)
(tag.acg as examples/tag.acg)
(tag-fr.acg as examples/tag-fr.acg)
(tag-script as examples/tag-script)
))
;; -*-lisp-*-
(jbuild_version 1)
(install
(
(package acgtk)
(section share)
(files (
(anbncndn.acg as examples/anbncndn.acg)
(cfg.acg as examples/cfg.acg)
(config.json as examples/config.json)
(demo-script as examples/demo-script)
(Jean-regarde-telescope.acg as examples/Jean-regarde-telescope.acg)
(MK-lecture-example.acg as examples/MK-lecture-example.acg)
(montague.acg as examples/montague.acg)
(montague-fr.acg as examples/montague-fr.acg)
(montague-script as examples/montague-script)
(README as examples/README)
(README.md as examples/README.md)
(strings.acg as examples/strings.acg)
(tag.acg as examples/tag.acg)
(tag-fr.acg as examples/tag-fr.acg)
(tag-script as examples/tag-script)
))))
#|(env
(dev
(flags (:standard -w +42)))
(release
(flags (:standard -58))))
|#
\ No newline at end of file
......@@ -2,17 +2,17 @@ opam-version: "1.2"
maintainer: "sylvain.pogodalla@inria.fr"
build: [
["jbuilder" "subst"] {pinned}
["dune" "subst"] {pinned}
# remove the -p to also build the local libraries: conflict with the
# fact that some libraries are also part of the acgtkLib package
# ["jbuilder" "build" "-p" name "-j" jobs]
["jbuilder" "build" "-j" jobs]
# ["dune" "build" "-p" name "-j" jobs]
["dune" "build" "-j" jobs]
]
install: ["jbuilder" "install"]
install: ["dune" "install"]
depends: [
"jbuilder" {build}
"dune" {build}
"dypgen"
"camlp4"
"bolt"
......
......@@ -18,7 +18,6 @@
(**************************************************************************)
open Logic
open Signature
module Data_Lexicon : Interface.Lexicon_sig
with
......
;; -*-lisp-*-
;; This stanza declares the AcgData library
(library
(name acgData)
(public_name acgtkLib.acgData)
(flags (:standard -w -58))
(preprocess (per_module
((action (system "%{bin:camlp4} -parser o -parser op -printer a -loc loc %{lib:bolt:bolt_pp.cmo} -level NONE %{input-file}" ))
reduction acg_lexicon type_system signature)
))
(libraries
logic ; internal library
datalogLib ; internal library
))
(documentation (package acgtk))
......@@ -19,8 +19,6 @@
open UtilsLib
type position = Lexing.position
let update_loc lexbuf file =
let pos = lexbuf.Lexing.lex_curr_p in
let new_file = match file with
......@@ -179,7 +177,7 @@ let version_error_to_string = function
let warning_to_string w =
match w with
| Variable_or_constant (s,pos1,pos2) -> Printf.sprintf "\"%s\" is a variable here, but is also declared as constant in the signature" s
| Variable_or_constant (s,_,_) -> Printf.sprintf "\"%s\" is a variable here, but is also declared as constant in the signature" s
let error_msg e input_file =
let msg,location_msg =
......@@ -195,7 +193,7 @@ let error_msg e input_file =
| None -> msg
| Some loc -> Printf.sprintf "File \"%s\", %s\n%s" input_file loc msg
let dyp_error lexbuf input_file =
let dyp_error lexbuf =
let pos1=Lexing.lexeme_start_p lexbuf in
let pos2=Lexing.lexeme_end_p lexbuf in
match bad_infix_usage () with
......@@ -205,7 +203,7 @@ let dyp_error lexbuf input_file =
let emit_warning w input_file =
match w with
| Variable_or_constant (s,pos1,pos2) ->
| Variable_or_constant (_,pos1,pos2) ->
let msg = warning_to_string w in
let line2 = pos2.Lexing.pos_lnum in
let col2 = pos2.Lexing.pos_cnum - pos2.Lexing.pos_bol in
......
......@@ -110,10 +110,10 @@ val unset_infix : unit -> unit
while the file [filename] is being processed *)
val error_msg : error -> string -> string
(** [dyp_error lexbuf filename] returns an exception {!Error.Error} so
that it can be caught in a uniform way. [lexbuf] and [filename] are
(** [dyp_error lexbuf] returns an exception {!Error.Error} so
that it can be caught in a uniform way. [lexbuf] is
used to set correctly the location information of the parse error *)
val dyp_error : Lexing.lexbuf -> string -> exn
val dyp_error : Lexing.lexbuf -> exn
(** [warnings_to_string filname ws] returns a string describing the
warnings anf their location for the file [filename] *)
......
;; -*-lisp-*-
(jbuild_version 1)
;; This stanza declares the AcgData library
(library
((name acgData)
(public_name acgtkLib.acgData)
(flags (:standard -w -58))
(preprocess (per_module
((action (system "${bin:camlp4} -parser o -parser op -printer a -loc loc ${lib:bolt:bolt_pp.cmo} -level NONE ${<}" ))
(reduction acg_lexicon type_system signature))
))
(libraries (
logic ; internal library
datalogLib ; internal library
))))
(documentation ((package acgtk)))
......@@ -23,7 +23,8 @@ struct
[obj_type=image_1 -> image_2 -> ... -> image_n]. Note that the
list is in the {em reverse order} and that [abs_type] should be
2nd order. *)
let map_types abs_type obj_type sg obj_sg=
let map_types abs_type obj_type sg =
let rec map_types_aux abs_type obj_type lst =
LOG "Mapping (aux) type:%s" (Sg.type_to_string abs_type sg) LEVEL TRACE;
LOG "On (aux): %s" (Lambda.raw_type_to_string obj_type) LEVEL TRACE;
......@@ -117,14 +118,14 @@ struct
object signature of some ACG. *)
let generate_and_add_rule
~abs_cst:(name,abs_t_type)
~abs_cst:(_,abs_t_type)
~obj_princ_type:principle_type
~obj_typing_env:env
prog
~abs_sig
~obj_sig =
let rule_id,prog=Datalog.Program.get_fresh_rule_id prog in
let type_lst = map_types abs_t_type principle_type abs_sig obj_sig in
let type_lst = map_types abs_t_type principle_type abs_sig in
match type_lst with
| [] -> failwith "Bug: there should be a type correspondance"
| (_,name,image)::tl ->
......@@ -171,7 +172,7 @@ struct
let edb_and_query ~obj_term ~obj_type ~obj_typing_env ~dist_type prog ~abs_sig ~obj_sig =
(* It makes the assumption that no constant has been
previously defined or used in the program *)
let type_lst = map_types dist_type obj_type abs_sig obj_sig in
let type_lst = map_types dist_type obj_type abs_sig in
match type_lst with
| [] -> failwith "Bug: there should be a type correspondance"
| [_,name,image] ->
......@@ -188,7 +189,7 @@ struct
([],prog) in
let prog=Datalog.Program.add_e_facts prog (e_facts,prog.Datalog.Program.const_table,prog.Datalog.Program.rule_id_gen) in
build_predicate_w_cst_args (name,image) prog
| (_,name,image)::tl -> failwith "Bug: querying non atomic types is not yet implemented"
| (_,_,_)::tl -> failwith "Bug: querying non atomic types is not yet implemented"
end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment