Commit cf1322a5 authored by MARTINEZ Thierry 's avatar MARTINEZ Thierry

SBML

parent 48f02cb8
......@@ -15,7 +15,7 @@ CFLAGS=$(addprefix -I, $(INCLUDEDIRS)) $(PLCFLAGS)
LDFLAGS=$(PLLDFLAGS) $(addprefix -L, $(dir $(wildcard $(PLBASE)/lib/*/)))
LDLIBS=$(PLLIB) `pkg-config --libs libgvc`
LDLIBS=$(PLLIB) `pkg-config --libs libgvc libsbml`
all: biocham biocham_debug test doc
......@@ -30,13 +30,18 @@ biocham_debug: platform/current swipl-biocham $(MODULES) $(TEST_MODULES) \
$(PWD)/swipl-biocham -o biocham_debug \
--goal=initialize -c $(MODULES) $(TEST_MODULES)
swipl-biocham: swipl-biocham.o modules/graphviz/graphviz_swiprolog.o
swipl-biocham: swipl-biocham.o \
modules/graphviz/graphviz_swiprolog.o \
modules/sbml/sbml_swiprolog.o
swipl-biocham.o: swipl-biocham.c
modules/graphviz/graphviz_swiprolog.o:
make -C modules/graphviz
modules/sbml/sbml_swiprolog.o:
make -C modules/sbml
platform/current:
- rm platform/current
ln -s `uname` platform/current
......@@ -54,6 +59,7 @@ biocham_tests: $(MODULES) $(TEST_MODULES) Makefile
clean:
- make -C modules/graphviz clean
- make -C modules/sbml clean
- rm platform/current
- rm biocham
- rm biocham_debug
......
#!/bin/bash
set -e
i=1
while true; do
filename=`printf BIOMD%.10d $i`
url="https://www.ebi.ac.uk/biomodels-main/download?mid=$filename"
if ! curl $url >$filename.xml; then
break
fi
((i++))
done
CC=swipl-ld
CFLAGS=`pkg-config --cflags libsbml`
LDLIBSx=`pkg-config --libs libsbml`
LDFLAGS=-shared
LDLIBS=`pkg-config --libs libsbml`
all: sbml2biocham
$(foreach var, PLSOEXT, \
$(eval \
$(shell \
swipl -dump-runtime-variables | \
grep ^$(var)= | \
sed -E 's/="/=/;s/";$$//')))
all: sbml_swiprolog test
.PHONY: clean test
clean:
rm -rf sbml2biocham sbml2biocham.o
- rm sbml_swiprolog
- rm sbml_swiprolog.o
sbml_swiprolog: sbml_swiprolog.o
swipl-ld -shared -o sbml_swiprolog sbml_swiprolog.o $(LDLIBS)
mv sbml_swiprolog.$(PLSOEXT) sbml_swiprolog
sbml_swiprolog.o: sbml_swiprolog.c
sbml2biocham: sbml2biocham.o
test:
swipl -g "\
call_cleanup((['sbml.plt'], run_tests, halt(0)), halt(1))\
"
:- module(
echo,
[
echo/1
]
).
:- use_module('../sbml').
echo(Filename) :-
readSBML(Filename, _SBML).
......@@ -18,11 +18,9 @@
speciesReference_getSpecies/2,
speciesReference_getStoichiometry/2,
modifierSpeciesReference_getSpecies/2,
modifierSpeciesReference_getStoichiometry/2,
species_getName/2,
species_getInitialAmount/2,
species_getInitialConcentration/2,
writeMathMLToString/2
species_getInitialConcentration/2
]
).
......
This diff is collapsed.
:- module(
platform,
[
open_file/1
]
).
open_file(Filename) :-
process_create(path('open'), [Filename], [process(Pid)]),
process_wait(Pid, exit(0)).
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment