diff --git a/databases/cdb/Makefile b/databases/cdb/Makefile index 8611cabdd0bb..a08fdfd8ab87 100644 --- a/databases/cdb/Makefile +++ b/databases/cdb/Makefile @@ -1,31 +1,42 @@ PORTNAME= cdb -PORTVERSION= 0.75 -PORTREVISION= 1 +DISTVERSION= 20251021 CATEGORIES= databases -MASTER_SITES= http://cr.yp.to/cdb/ +MASTER_SITES= https://cdb.cr.yp.to/ -MAINTAINER= ports@FreeBSD.org +MAINTAINER= mce@FreeBSD.org COMMENT= Fast lookup database library & utilities -WWW= https://cr.yp.to/cdb.html +WWW= https://cdb.cr.yp.to/ + +LICENSE= PD +LICENSE_FILE= ${WRKSRC}/doc/license.md ALL_TARGET= it CFLAGS_amd64= -fPIC +PORTDOCS= * + +OPTIONS_DEFINE= DOCS + do-configure: @${MV} ${WRKSRC}/conf-home ${WRKSRC}/conf-home.orig ${ECHO_CMD} ${PREFIX} > ${WRKSRC}/conf-home @${MV} ${WRKSRC}/conf-cc ${WRKSRC}/conf-cc.orig ${ECHO_CMD} ${CC} ${CFLAGS} > ${WRKSRC}/conf-cc @${MV} ${WRKSRC}/conf-ld ${WRKSRC}/conf-ld.orig ${ECHO_CMD} ${CC} -s > ${WRKSRC}/conf-ld do-install: -.for file in cdbdump cdbget cdbmake cdbstats cdbtest - ${INSTALL_PROGRAM} ${WRKSRC}/${file} ${STAGEDIR}${PREFIX}/bin -.endfor -.for file in cdbmake-12 cdbmake-sv - ${INSTALL_SCRIPT} ${WRKSRC}/${file} ${STAGEDIR}${PREFIX}/bin -.endfor + cd ${WRKSRC} && ${INSTALL_PROGRAM} cdbdump cdbget cdbmake cdbstats \ + cdbtest cdb64dump cdb64get cdb64make cdb64stats cdb64test \ + ${STAGEDIR}${PREFIX}/bin + cd ${WRKSRC} && ${INSTALL_SCRIPT} cdbmake-12 cdbmake-sv \ + cdb64make-12 cdb64make-sv ${STAGEDIR}${PREFIX}/bin + +# cdb.3 conflicts with databases/tinycdb, so do not install man pages in MANDIRS. +do-install-DOCS-on: + ${GZIP_CMD} ${WRKSRC}/doc/man/* + @${MKDIR} ${STAGEDIR}${DOCSDIR} + cd ${WRKSRC}/doc && ${COPYTREE_SHARE} "*" ${STAGEDIR}${DOCSDIR} .include diff --git a/databases/cdb/distinfo b/databases/cdb/distinfo index 342a66c494f4..42ade53974aa 100644 --- a/databases/cdb/distinfo +++ b/databases/cdb/distinfo @@ -1,2 +1,3 @@ -SHA256 (cdb-0.75.tar.gz) = 1919577799a50c080a8a05a1cbfa5fa7e7abc823d8d7df2eeb181e624b7952c5 -SIZE (cdb-0.75.tar.gz) = 54162 +TIMESTAMP = 1761534367 +SHA256 (cdb-20251021.tar.gz) = 8e531d6390bcd7c9a4cbd16fed36326eee78e8b0e5c0783a8158a6a79437e3dd +SIZE (cdb-20251021.tar.gz) = 111952 diff --git a/databases/cdb/files/patch-error.h b/databases/cdb/files/patch-error.h deleted file mode 100644 index e35ddb04802a..000000000000 --- a/databases/cdb/files/patch-error.h +++ /dev/null @@ -1,11 +0,0 @@ ---- error.h.orig -+++ error.h -@@ -1,7 +1,7 @@ - #ifndef ERROR_H - #define ERROR_H - --extern int errno; -+#include - - extern int error_intr; - extern int error_nomem; diff --git a/databases/cdb/pkg-descr b/databases/cdb/pkg-descr index 8b98bd7653ba..51e8039db0f1 100644 --- a/databases/cdb/pkg-descr +++ b/databases/cdb/pkg-descr @@ -1,22 +1,20 @@ cdb is a fast, reliable, lightweight package for creating and reading constant databases. Its database structure provides several features: -* Fast lookups: A successful lookup in a large database normally takes - just two disk accesses. An unsuccessful lookup takes only one. -* Low overhead: A database uses 2048 bytes, plus 24 bytes per record, - plus the space for keys and data. -* No random limits: cdb can handle any database up to 4 gigabytes. There - are no other restrictions; records don't even have to fit into memory. - Databases are stored in a machine-independent format. -* Fast atomic database replacement: cdbmake can rewrite an entire - database two orders of magnitude faster than other hashing packages. -* Fast database dumps: cdbdump prints the contents of a database in +* Fast lookups: A successful lookup in a large database normally + takes just two disk accesses. An unsuccessful lookup takes only one. +* Low overhead: A database uses 2048 bytes (or 4096 bytes for cdb64), + plus 24 bytes per record (or 48 bytes per record for cdb64), plus + the space for keys and data. +* No random limits: cdb can handle any database up to 4 gigabytes + (or up to an exabyte for cdb64). There are no other restrictions. + Records are streamed and don't have to fit into memory. + Databases are stored in a machine-independent format (one format for + cdb, one format for cdb64). +* Fast atomic database replacement: `cdbmake` rewrites an entire + database much more quickly than other hashing packages. Database + replacement is safe against system crashes. Readers don't pause + during a rewrite: they continue transparently using the old database + until the new database is in place. +* Fast database dumps: `cdbdump` prints the contents of a database in cdbmake-compatible format. - -cdb is designed to be used in mission-critical applications like e-mail. -Database replacement is safe against system crashes. Readers don't have -to pause during a rewrite. - -Note for developers: packages that need to read cdb files should -incorporate the necessary portions of the cdb library rather than -relying on an external cdb library. (See WWW) diff --git a/databases/cdb/pkg-plist b/databases/cdb/pkg-plist index 83a20b3f2ce1..da5dd0bff0bd 100644 --- a/databases/cdb/pkg-plist +++ b/databases/cdb/pkg-plist @@ -1,7 +1,14 @@ +bin/cdb64dump +bin/cdb64get +bin/cdb64make +bin/cdb64make-12 +bin/cdb64make-sv +bin/cdb64stats +bin/cdb64test bin/cdbdump bin/cdbget bin/cdbmake bin/cdbmake-12 bin/cdbmake-sv bin/cdbstats bin/cdbtest