diff --git a/biology/Makefile b/biology/Makefile index f57fe3e300fd..5e85d456e039 100644 --- a/biology/Makefile +++ b/biology/Makefile @@ -1,219 +1,220 @@ COMMENT = Biology SUBDIR += abyss SUBDIR += ad2vcf SUBDIR += artemis SUBDIR += avida SUBDIR += babel SUBDIR += bamtools SUBDIR += bbmap SUBDIR += bcftools SUBDIR += bedtools SUBDIR += bfc SUBDIR += bioawk SUBDIR += biococoa SUBDIR += biolibc SUBDIR += biolibc-tools SUBDIR += bioparser SUBDIR += biosig SUBDIR += biosoup SUBDIR += biostar-tools SUBDIR += bolt-lmm SUBDIR += bowtie SUBDIR += bowtie2 SUBDIR += bwa SUBDIR += canu SUBDIR += cd-hit SUBDIR += cdbfasta SUBDIR += checkm SUBDIR += clustal-omega SUBDIR += clustalw SUBDIR += cufflinks SUBDIR += cytoscape SUBDIR += ddocent SUBDIR += diamond SUBDIR += dsr-pdb SUBDIR += edlib SUBDIR += emboss SUBDIR += erminej SUBDIR += exonerate SUBDIR += fasta SUBDIR += fasta3 SUBDIR += fastahack SUBDIR += fastdnaml SUBDIR += fastool SUBDIR += fastp SUBDIR += fastqc SUBDIR += fasttree SUBDIR += fastx-toolkit SUBDIR += figtree SUBDIR += flash SUBDIR += fluctuate SUBDIR += freebayes SUBDIR += garlic SUBDIR += gatk SUBDIR += gcta SUBDIR += gemma SUBDIR += generand SUBDIR += gff2ps SUBDIR += gmap SUBDIR += gperiodic SUBDIR += graphlan SUBDIR += groopm SUBDIR += haplohseq SUBDIR += hhsuite SUBDIR += hisat2 SUBDIR += hmmer SUBDIR += htslib SUBDIR += hyphy SUBDIR += igv SUBDIR += infernal SUBDIR += iolib SUBDIR += iqtree SUBDIR += jalview SUBDIR += jellyfish SUBDIR += kallisto SUBDIR += lamarc SUBDIR += libbigwig SUBDIR += libgtextutils SUBDIR += libnuml SUBDIR += libsbml SUBDIR += libsedml SUBDIR += linux-foldingathome SUBDIR += mafft SUBDIR += mapm3 SUBDIR += migrate SUBDIR += minimap2 SUBDIR += mmseqs2 SUBDIR += molden SUBDIR += mopac SUBDIR += mothur SUBDIR += mrbayes SUBDIR += mummer SUBDIR += muscle SUBDIR += ncbi-blast+ SUBDIR += ncbi-cxx-toolkit SUBDIR += ncbi-entrez-direct SUBDIR += ncbi-toolkit SUBDIR += ncbi-vdb SUBDIR += ngs-sdk SUBDIR += p5-AcePerl SUBDIR += p5-Bio-ASN1-EntrezGene SUBDIR += p5-Bio-Cluster SUBDIR += p5-Bio-Coordinate SUBDIR += p5-Bio-DB-EMBL SUBDIR += p5-Bio-DB-NCBIHelper SUBDIR += p5-Bio-Das SUBDIR += p5-Bio-Das-Lite SUBDIR += p5-Bio-FeatureIO SUBDIR += p5-Bio-GFF3 SUBDIR += p5-Bio-Glite SUBDIR += p5-Bio-Graphics SUBDIR += p5-Bio-MAGETAB SUBDIR += p5-Bio-NEXUS SUBDIR += p5-Bio-Phylo SUBDIR += p5-Bio-SCF SUBDIR += p5-Bio-Variation SUBDIR += p5-BioPerl SUBDIR += p5-BioPerl-Run SUBDIR += p5-TrimGalore SUBDIR += p5-transdecoder SUBDIR += paml SUBDIR += pbbam SUBDIR += pbseqan SUBDIR += peak-classifier SUBDIR += pear-merger SUBDIR += phrap SUBDIR += phred SUBDIR += phyml SUBDIR += picard-tools SUBDIR += plink SUBDIR += pooler SUBDIR += primer3 SUBDIR += prodigal SUBDIR += prodigy-lig SUBDIR += protomol SUBDIR += psi88 SUBDIR += py-Genesis-PyAPI SUBDIR += py-PySCeS SUBDIR += py-bigwig SUBDIR += py-biom-format SUBDIR += py-biopython SUBDIR += py-bx-python SUBDIR += py-crossmap SUBDIR += py-cutadapt SUBDIR += py-dnaio SUBDIR += py-ete3 SUBDIR += py-gffutils SUBDIR += py-goatools SUBDIR += py-gtfparse SUBDIR += py-hits SUBDIR += py-loompy SUBDIR += py-macs2 SUBDIR += py-multiqc SUBDIR += py-libnuml + SUBDIR += py-libsedml SUBDIR += py-ont-fast5-api SUBDIR += py-orange3-bioinformatics SUBDIR += py-orange3-single-cell SUBDIR += py-pandas-charm SUBDIR += py-pyfaidx SUBDIR += py-pysam SUBDIR += py-python-libsbml SUBDIR += py-pywgsim SUBDIR += py-resdk SUBDIR += py-scikit-bio SUBDIR += py-xenaPython SUBDIR += pyfasta SUBDIR += python-nexus SUBDIR += rainbow SUBDIR += rampler SUBDIR += readseq SUBDIR += recombine SUBDIR += ruby-bio SUBDIR += rubygem-bio SUBDIR += rubygem-bio-executables SUBDIR += rubygem-bio-old-biofetch-emulator SUBDIR += rubygem-bio-shell SUBDIR += sam2pairwise SUBDIR += samtools SUBDIR += scrm SUBDIR += seaview SUBDIR += seqan SUBDIR += seqan-apps SUBDIR += seqan1 SUBDIR += seqan3 SUBDIR += seqio SUBDIR += seqkit SUBDIR += seqtk SUBDIR += sigviewer SUBDIR += sim4 SUBDIR += slclust SUBDIR += smithwaterman SUBDIR += snpeff SUBDIR += spoa SUBDIR += sra-tools SUBDIR += stacks SUBDIR += star SUBDIR += stringtie SUBDIR += subread SUBDIR += tRNAscan-SE SUBDIR += tabixpp SUBDIR += taxonkit SUBDIR += treekin SUBDIR += treepuzzle SUBDIR += trimadap SUBDIR += trimmomatic SUBDIR += ucsc-userapps SUBDIR += ugene SUBDIR += unikmer SUBDIR += vcf-split SUBDIR += vcf2hap SUBDIR += vcflib SUBDIR += vcftools SUBDIR += velvet SUBDIR += viennarna SUBDIR += vsearch SUBDIR += vt SUBDIR += wise .include diff --git a/biology/py-libsedml/Makefile b/biology/py-libsedml/Makefile new file mode 100644 index 000000000000..d1432f390993 --- /dev/null +++ b/biology/py-libsedml/Makefile @@ -0,0 +1,34 @@ +PORTNAME= libsedml +DISTVERSIONPREFIX= v +DISTVERSION= 2.0.26 +CATEGORIES= biology devel +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} + +MAINTAINER= yuri@FreeBSD.org +COMMENT= SED-ML library for Python + +LICENSE= BSD2CLAUSE +LICENSE_FILE= ${WRKSRC}/../../../LICENSE.txt + +BUILD_DEPENDS= swig:devel/swig +LIB_DEPENDS= libsedml.so:biology/libsedml \ + libsbml.so:biology/libsbml \ + libnuml.so:biology/libnuml + +USES= cmake localbase:ldflags python +USE_PYTHON= flavors + +USE_GITHUB= yes +GH_ACCOUNT= fbergmann +GH_PROJECT= libSEDML + +CMAKE_ARGS= -DCMAKE_INSTALL_LIBDIR=lib + +LDFLAGS+= -lsedml -lsbml -lnuml # otherwise it builds a broken shared object, see https://github.com/NuML/NuML/issues/21 + +WRKSRC_SUBDIR= src/bindings/python + +do-test: install + @${PYTHON_CMD} ${FILESDIR}/quick-test.py + +.include diff --git a/biology/py-libsedml/distinfo b/biology/py-libsedml/distinfo new file mode 100644 index 000000000000..305ade0a4d35 --- /dev/null +++ b/biology/py-libsedml/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1632069547 +SHA256 (fbergmann-libSEDML-v2.0.26_GH0.tar.gz) = 74334f2d2e0f4aae2f58f4013c432220ba12a6a6be4cf9478adbbefab7441b41 +SIZE (fbergmann-libSEDML-v2.0.26_GH0.tar.gz) = 956845 diff --git a/biology/py-libsedml/files/patch-CMakeLists.txt b/biology/py-libsedml/files/patch-CMakeLists.txt new file mode 100644 index 000000000000..0a8f6e634f59 --- /dev/null +++ b/biology/py-libsedml/files/patch-CMakeLists.txt @@ -0,0 +1,22 @@ +--- CMakeLists.txt.orig 2021-09-19 17:41:37 UTC ++++ CMakeLists.txt +@@ -49,6 +49,7 @@ ADD_CUSTOM_COMMAND( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/libsedml_wrap.cpp + COMMAND "${SWIG_EXECUTABLE}" + ARGS -I${CMAKE_CURRENT_SOURCE_DIR}/../swig/ ++ -I${CMAKE_INSTALL_PREFIX}/include + -I${CMAKE_CURRENT_SOURCE_DIR}/../../ + -I${CMAKE_CURRENT_BINARY_DIR}/../../ + -I${CMAKE_CURRENT_SOURCE_DIR}/../../sedml +@@ -125,9 +126,9 @@ if (PYTHON_USE_DYNAMIC_LOOKUP) + if (APPLE) + set_target_properties (binding_python_lib PROPERTIES LINK_FLAGS "-undefined dynamic_lookup") + endif() +- target_link_libraries(binding_python_lib ${LIBSEDML_LIBRARY}-static) ++ target_link_libraries(binding_python_lib ${LIBSEDML_LIBRARY}) + else() +- target_link_libraries(binding_python_lib ${LIBSEDML_LIBRARY}-static ${PYTHON_LIBRARIES}) ++ target_link_libraries(binding_python_lib ${LIBSEDML_LIBRARY} ${PYTHON_LIBRARIES}) + endif() + + # diff --git a/biology/py-libsedml/files/quick-test.py b/biology/py-libsedml/files/quick-test.py new file mode 100644 index 000000000000..59be4485ce6d --- /dev/null +++ b/biology/py-libsedml/files/quick-test.py @@ -0,0 +1,20 @@ +# from https://github.com/fbergmann/libSEDML/issues/152 + +import libsedml + +# create data set +data_set = libsedml.SedDataSet() + +# set id +assert data_set.setId('obj') == 0 + +# check id set +assert data_set.getId() == 'obj' + +# set empty name +assert data_set.setName('') == 0 + +# id is no longer set! +assert data_set.getId() == 'obj' + +print("Test passed"); diff --git a/biology/py-libsedml/pkg-descr b/biology/py-libsedml/pkg-descr new file mode 100644 index 000000000000..c84d1db60018 --- /dev/null +++ b/biology/py-libsedml/pkg-descr @@ -0,0 +1,6 @@ +Python binding libSEDML. + +The libSEDML project makes use of libSBML XML layer as well as code generation +as starting point to produce a library for reading and writing of SED-ML models. + +WWW: https://github.com/fbergmann/libSEDML diff --git a/biology/py-libsedml/pkg-plist b/biology/py-libsedml/pkg-plist new file mode 100644 index 000000000000..81ce476b7592 --- /dev/null +++ b/biology/py-libsedml/pkg-plist @@ -0,0 +1,3 @@ +%%PYTHON_SITELIBDIR%%/libsedml.pth +%%PYTHON_SITELIBDIR%%/libsedml/_libsedml.so +%%PYTHON_SITELIBDIR%%/libsedml/libsedml.py