diff --git a/science/cif-tools/Makefile b/science/cif-tools/Makefile index 7f82466380ea..8a4121c89c90 100644 --- a/science/cif-tools/Makefile +++ b/science/cif-tools/Makefile @@ -1,23 +1,23 @@ PORTNAME= cif-tools DISTVERSIONPREFIX= v -DISTVERSION= 1.0.13 +DISTVERSION= 2.0.0 CATEGORIES= science # chemistry MAINTAINER= yuri@FreeBSD.org COMMENT= Suite of programs to manipulate and examine mmCIF files WWW= https://github.com/PDB-REDO/cif-tools LICENSE= BSD2CLAUSE LICENSE_FILE= ${WRKSRC}/LICENSE BUILD_DEPENDS= libmcfp>0:devel/libmcfp \ mrc:devel/mrc LIB_DEPENDS= libboost_iostreams.so:devel/boost-libs \ libcifpp.so:science/libcifpp USES= cmake:noninja compiler:c++17-lang # ninja: error: build.ninja:890: multiple rules generate ALL USE_GITHUB= yes GH_ACCOUNT= PDB-REDO .include diff --git a/science/cif-tools/distinfo b/science/cif-tools/distinfo index e81d1d7f7fb0..2c93e104b224 100644 --- a/science/cif-tools/distinfo +++ b/science/cif-tools/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1774151757 -SHA256 (PDB-REDO-cif-tools-v1.0.13_GH0.tar.gz) = 0d18a69c18fbaf8f4fc59b85b3a171de613734ea34f524e86ee79f17c50cc4be -SIZE (PDB-REDO-cif-tools-v1.0.13_GH0.tar.gz) = 1839479 +TIMESTAMP = 1778653321 +SHA256 (PDB-REDO-cif-tools-v2.0.0_GH0.tar.gz) = 8f19a41a47bbfa1e1f3b221dcb7e3c59b419da2e6e95b72019ad0fd29523e503 +SIZE (PDB-REDO-cif-tools-v2.0.0_GH0.tar.gz) = 1850337 diff --git a/science/cif-tools/files/patch-src_cif-diff.cpp b/science/cif-tools/files/patch-src_cif-diff.cpp deleted file mode 100644 index 32f536844126..000000000000 --- a/science/cif-tools/files/patch-src_cif-diff.cpp +++ /dev/null @@ -1,42 +0,0 @@ ---- src/cif-diff.cpp.orig 2026-03-22 05:31:17 UTC -+++ src/cif-diff.cpp -@@ -133,7 +133,7 @@ class templateParser : public cif::sac_parser - { - } - -- void produce_item(std::string_view category, std::string_view item, std::string_view value) override -+ void produce_item(std::string_view category, std::string_view item, cif::item_value value) override - { - std::ostringstream tag; - tag << '_' << category << '.' << item; -@@ -195,7 +195,7 @@ void compareCategories(cif::category &a, cif::category - - tie(tag, compare) = tags[kix]; - -- d = compare(a[tag].text(), b[tag].text()); -+ d = compare(a[tag].sv(), b[tag].sv()); - - if (d != 0) - break; -@@ -334,10 +334,10 @@ void compareCategories(cif::category &a, cif::category - - // make it an option to compare unapplicable to empty or something - -- std::string_view ta = ra[tag].text(); -+ std::string_view ta = ra[tag].sv(); - if (ta == ".") - ta = ""; -- std::string_view tb = rb[tag].text(); -+ std::string_view tb = rb[tag].sv(); - if (tb == ".") - tb = ""; - -@@ -361,7 +361,7 @@ void compareCategories(cif::category &a, cif::category - - if (not diffs.empty()) - { -- std::cout << std::string(mcfp::get_terminal_width(), '-') << '\n' -+ std::cout << std::string(cif::get_terminal_width(), '-') << '\n' - << "Differences in values for category " << a.name() << '\n' - << '\n'; - diff --git a/science/cif-tools/files/patch-src_cif-grep.cpp b/science/cif-tools/files/patch-src_cif-grep.cpp deleted file mode 100644 index aff0c6720114..000000000000 --- a/science/cif-tools/files/patch-src_cif-grep.cpp +++ /dev/null @@ -1,16 +0,0 @@ ---- src/cif-grep.cpp.orig 2026-03-22 05:31:17 UTC -+++ src/cif-grep.cpp -@@ -70,11 +70,11 @@ class statsParser : public cif::sac_parser - { - } - -- void produce_item(std::string_view category, std::string_view item, std::string_view value) override -+ void produce_item(std::string_view category, std::string_view item, cif::item_value value) override - { - if ((mCat.empty() or cif::iequals(category, mCat)) and - (mItem.empty() or cif::iequals(item, mItem)) and -- std::regex_search(value.begin(), value.end(), mRx) == not mInvertMatch) -+ std::regex_search(value.sv().begin(), value.sv().end(), mRx) == not mInvertMatch) - { - ++mMatches; - diff --git a/science/cif-tools/files/patch-src_cif-validate.cpp b/science/cif-tools/files/patch-src_cif-validate.cpp deleted file mode 100644 index fd845a559b6c..000000000000 --- a/science/cif-tools/files/patch-src_cif-validate.cpp +++ /dev/null @@ -1,26 +0,0 @@ ---- src/cif-validate.cpp.orig 2026-03-22 05:31:17 UTC -+++ src/cif-validate.cpp -@@ -52,7 +52,7 @@ class dummy_parser : public cif::sac_parser - { - } - -- void produce_item(std::string_view category, std::string_view item, std::string_view value) override -+ void produce_item(std::string_view category, std::string_view item, cif::item_value value) override - { - } - }; -@@ -112,12 +112,12 @@ int pr_main(int argc, char *argv[]) - for (auto &db : f) - { - if (config.count("dict")) -- db.set_validator(&cif::validator_factory::instance().get(config.get("dict"))); -+ db.set_validator(cif::validator_factory::instance().get(config.get("dict"))); - else - db.load_dictionary(); - - if (db.get_validator() == nullptr) -- db.set_validator(&cif::validator_factory::instance().get("mmcif_pdbx.dic")); -+ db.set_validator(cif::validator_factory::instance().get("mmcif_pdbx.dic")); - - if (not const_cast(db).is_valid()) - result = 1; diff --git a/science/cif-tools/files/patch-src_cif2pdb.cpp b/science/cif-tools/files/patch-src_cif2pdb.cpp deleted file mode 100644 index e5d17751ffdf..000000000000 --- a/science/cif-tools/files/patch-src_cif2pdb.cpp +++ /dev/null @@ -1,14 +0,0 @@ ---- src/cif2pdb.cpp.orig 2026-03-22 05:31:17 UTC -+++ src/cif2pdb.cpp -@@ -92,9 +92,9 @@ int pr_main(int argc, char *argv[]) - - // Load dict, if any - if (config.has("dict")) -- f.front().set_validator(&cif::validator_factory::instance().get(config.get("dict"))); -+ f.front().set_validator(cif::validator_factory::instance().get(config.get("dict"))); - else if (f.front().get_validator() == nullptr) -- f.front().set_validator(&cif::validator_factory::instance().get("mmcif_pdbx.dic")); -+ f.front().set_validator(cif::validator_factory::instance().get("mmcif_pdbx.dic")); - - if (f.empty() or (not config.has("no-validate") and not f.is_valid())) - { diff --git a/science/cif-tools/files/patch-src_mmCQL.cpp b/science/cif-tools/files/patch-src_mmCQL.cpp deleted file mode 100644 index c18f5e4d38a2..000000000000 --- a/science/cif-tools/files/patch-src_mmCQL.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- src/mmCQL.cpp.orig 2026-03-22 05:31:17 UTC -+++ src/mmCQL.cpp -@@ -1182,7 +1182,7 @@ StatementPtr Parser::ParseUpdate() - } - - if (iv) -- iv->operator()(value); -+ iv->validate_value(value); - - itemValuePairs.emplace_back(item, value); - diff --git a/science/cif-tools/files/patch-src_pr-main.cpp b/science/cif-tools/files/patch-src_pr-main.cpp new file mode 100644 index 000000000000..7dcd67a7e1ba --- /dev/null +++ b/science/cif-tools/files/patch-src_pr-main.cpp @@ -0,0 +1,10 @@ +--- src/pr-main.cpp.orig 2026-05-13 06:50:56 UTC ++++ src/pr-main.cpp +@@ -29,6 +29,7 @@ + #include + #endif + ++#include + #include + #include + #include diff --git a/science/cif-tools/pkg-plist b/science/cif-tools/pkg-plist index 35def740b7af..c01f04ec485e 100644 --- a/science/cif-tools/pkg-plist +++ b/science/cif-tools/pkg-plist @@ -1,14 +1,12 @@ bin/cif-diff -bin/cif-grep bin/cif-merge bin/cif-validate bin/cif2pdb -bin/mmCQL +bin/mmcql bin/pdb2cif share/man/man1/cif-diff.1.gz -share/man/man1/cif-grep.1.gz share/man/man1/cif-merge.1.gz share/man/man1/cif-validate.1.gz share/man/man1/cif2pdb.1.gz -share/man/man1/mmCQL.1.gz +share/man/man1/mmcql.1.gz share/man/man1/pdb2cif.1.gz