# $FreeBSD$ PORTNAME= go-cve-dictionary DISTVERSIONPREFIX= v DISTVERSION= 0.1.1-1 DISTVERSIONSUFFIX= -gb3b5265 CATEGORIES= security MAINTAINER= iscandr@gmail.com COMMENT= Build local copies of vulnerabilities from NVD and JVN LICENSE= APACHE20 RUN_DEPENDS= ca_root_nss>=0:security/ca_root_nss USES= go:1.7.1+ USE_RC_SUBR= ${PORTNAME} USE_GITHUB= yes GH_ACCOUNT= kotakanbe GH_SUBDIR= src/github.com/${GH_ACCOUNT_DEFAULT}/${PORTNAME} GH_TUPLE+= VividCortex:ewma:v1.0:ewma/src/gopkg.in/VividCortex/ewma.v1 GH_TUPLE+= asaskevich:govalidator:v6:govalidator/src/github.com/asaskevich/govalidator GH_TUPLE+= camlistore:go4:034d17a:go4syncutil/src/go4.org GH_TUPLE+= cheggaaa:pb:v2.0.4:pb/src/gopkg.in/cheggaaa/pb.v2 GH_TUPLE+= dgrijalva:jwt-go:v3.0.0:jwtgo/src/github.com/dgrijalva/jwt-go GH_TUPLE+= fatih:color:v1.5.0:colorv1/src/gopkg.in/fatih/color.v1 GH_TUPLE+= go-redis:redis:v6.5.0:redis/src/github.com/go-redis/redis GH_TUPLE+= go-sql-driver:mysql:v1.3:mysql/src/github.com/go-sql-driver/mysql GH_TUPLE+= golang:crypto:558b687:golangcrypto/src/golang.org/x/crypto GH_TUPLE+= golang:net:5f8847a:golangnet/src/golang.org/x/net GH_TUPLE+= golang:sys:0f826bd:golangsys/src/golang.org/x/sys GH_TUPLE+= google:subcommands:ce3d4cf:subcommands/src/github.com/google/subcommands GH_TUPLE+= jinzhu:gorm:eae7f6b:gorm/src/github.com/jinzhu/gorm GH_TUPLE+= jinzhu:inflection:1c35d90:inflection/src/github.com/jinzhu/inflection GH_TUPLE+= k0kubun:pp:v2.3.0:pp/src/github.com/k0kubun/pp GH_TUPLE+= kotakanbe:logrus-prefixed-formatter:75edb2e:logrusprefixedformatter/src/github.com/kotakanbe/logrus-prefixed-formatter GH_TUPLE+= labstack:echo:bc173df:echo/src/github.com/labstack/echo GH_TUPLE+= labstack:gommon:1121fd3:gommon/src/github.com/labstack/gommon GH_TUPLE+= lib:pq:8837942:pq/src/github.com/lib/pq GH_TUPLE+= mattn:go-colorable:v0.0.8:gocolorable/src/github.com/mattn/go-colorable GH_TUPLE+= mattn:go-isatty:v0.0.2:goisatty/src/github.com/mattn/go-isatty GH_TUPLE+= mattn:go-runewidth:97311d9:gorunewidth/src/github.com/mattn/go-runewidth GH_TUPLE+= mattn:go-sqlite3:v1.2.0:gosqlite3/src/github.com/mattn/go-sqlite3 GH_TUPLE+= mgutz:ansi:9520e82:ansi/src/github.com/mgutz/ansi GH_TUPLE+= moul:http2curl:4e24498:http2curl/src/github.com/moul/http2curl GH_TUPLE+= parnurzeal:gorequest:v0.2.15:gorequest/src/github.com/parnurzeal/gorequest GH_TUPLE+= pkg:errors:c605e28:pkgerrors/src/github.com/pkg/errors GH_TUPLE+= rifflock:lfshook:1.7:lfshook/src/github.com/rifflock/lfshook GH_TUPLE+= sirupsen:logrus:1.0.2:logrus/src/github.com/sirupsen/logrus GH_TUPLE+= valyala:fasttemplate:dcecefd:fasttemplate/src/github.com/valyala/fasttemplate USERS= vuls GROUPS= vuls SUB_FILES= pkg-message SUB_LIST= PORTNAME=${PORTNAME} USERS=${USERS} GROUPS=${GROUPS} post-patch: @${REINPLACE_CMD} -e 's|github.com/cheggaaa/pb|gopkg.in/cheggaaa/pb.v2|' \ ${WRKSRC}/db/rdb.go \ ${WRKSRC}/db/redis.go \ ${WRKSRC}/jvn/jvn.go \ ${WRKSRC}/nvd/nvd.go @${REINPLACE_CMD} -e 's|gopkg.in/mattn/go-runewidth.v0|github.com/mattn/go-runewidth|' \ ${WRKSRC}/src/gopkg.in/cheggaaa/pb.v2/util.go @${REINPLACE_CMD} -e 's|gopkg.in/mattn/go-colorable.v0|github.com/mattn/go-colorable|' \ ${WRKSRC}/src/gopkg.in/cheggaaa/pb.v2/pb.go @${REINPLACE_CMD} -e 's|gopkg.in/mattn/go-isatty.v0|github.com/mattn/go-isatty|' \ ${WRKSRC}/src/gopkg.in/cheggaaa/pb.v2/pb.go do-build: @cd ${GO_WRKSRC} && \ ${SETENV} ${MAKE_ENV} ${GO_ENV} GOPATH=${WRKSRC} \ ${GO_CMD} build -v -x -ldflags "-X main.version=${PORTVERSION}" \ -o ${WRKSRC}/${PORTNAME} do-install: ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin/${PORTNAME} ${MKDIR} ${STAGEDIR}/var/db/vuls ${MKDIR} ${STAGEDIR}/var/log/vuls .include