From owner-freebsd-ports@freebsd.org Tue Apr 18 13:09:34 2017 Return-Path: Delivered-To: freebsd-ports@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 44B09D42EA1 for ; Tue, 18 Apr 2017 13:09:34 +0000 (UTC) (envelope-from steven@multiplay.co.uk) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id 23AF01643 for ; Tue, 18 Apr 2017 13:09:34 +0000 (UTC) (envelope-from steven@multiplay.co.uk) Received: by mailman.ysv.freebsd.org (Postfix) id 1FB10D42EA0; Tue, 18 Apr 2017 13:09:34 +0000 (UTC) Delivered-To: ports@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1F483D42E9F for ; Tue, 18 Apr 2017 13:09:34 +0000 (UTC) (envelope-from steven@multiplay.co.uk) Received: from mail-oi0-x22d.google.com (mail-oi0-x22d.google.com [IPv6:2607:f8b0:4003:c06::22d]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D9ACE1642 for ; Tue, 18 Apr 2017 13:09:33 +0000 (UTC) (envelope-from steven@multiplay.co.uk) Received: by mail-oi0-x22d.google.com with SMTP id b187so176061455oif.0 for ; Tue, 18 Apr 2017 06:09:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=multiplay-co-uk.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=DvAs6IiRo5H97hClhYZxwWEtWJhsqA8ZQQrMbBGsLm0=; b=fVS8n4H3bAF0UTjJpMMwfZun0Fy9dbvjiLp4Zau7IJBBLXrkUHvl88ALLNuYfLXpIP A7rP0zusnab+lgI+1mYK6dkE5LTQLbMlnsXPc2pg0HuCJ/YwfOZg2CuX1O+A4e0Q1QtV 4sbdmclfI0PxQ6FCYh6n9TOJZM4xao8arf5Rwc8pmd/qP//H9yPfzkKpcc3LNbyuk4uk fLwaWbRPN8youhqJC/qjBe2hc0UrwMAvfUsP98I5pceoZTLH6U32+mHLASXwjN86pDE0 MUj+Fl02eBW80186QVxxm35aHE3lvpRAJq+7Zvs5yMajJXbnzUkYwomI5hYT91mDEeI/ z2hw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=DvAs6IiRo5H97hClhYZxwWEtWJhsqA8ZQQrMbBGsLm0=; b=sZA6932J30VeS8FvURH/paRfBqNQ3w6eO3vf3oVMiSO3uTwvNqI17skntzrQMMWsBz UZQoiCeWFXd4fvPyZA/cHtJaHxcdGH3YGcVNom5XAJ+VzZZ5ivJiKmTStxVK6421kCpy v+ZPpdSpcdsAx5tlCOSM5AahebZWh+z7vW7aVtHfnqq7UfeCb+B8V9E4w6d6k+Xhzsxe 4ETGMVvEiwEd1R7fBkqbZA5qIJ4dUXKbV8tXmTEEI2ZRupq++1otTLD0F8SXPmhtcwwU pDtJk9E0sYH0VbusrjLv5JQkhWU51vv06OCUdD40P0PCxfplov5TtIwO2HAexowRE6aW cNiQ== X-Gm-Message-State: AN3rC/4Mt4z2+n0rCQfyFT2e88mU8RTYh/KnoGeQMsKdm40ROwWpnvch NlagCDplTnl3jion2McaD3XAL/0AbWKl3b8= X-Received: by 10.157.60.145 with SMTP id z17mr5198731otc.252.1492520973139; Tue, 18 Apr 2017 06:09:33 -0700 (PDT) MIME-Version: 1.0 References: <20170418103350.433498f4@arria.bitmark.lan> In-Reply-To: <20170418103350.433498f4@arria.bitmark.lan> From: Steven Hartland Date: Tue, 18 Apr 2017 13:09:22 +0000 Message-ID: Subject: Re: Packaging Go Libs To: Christopher Hall , Steve Wills Cc: ports@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Apr 2017 13:09:34 -0000 You should use built in golang vendoring to ensure these dependencies, as their is no guarantee that someone won't update the library port and your app would break, so doing that is very fragile On Tue, 18 Apr 2017 at 03:34, Christopher Hall < christopherhall.hsw@gmail.com> wrote: > Hello Steve, > > On Mon, 17 Apr 2017 10:20:20 -0400, Steve Wills wrote: > > > Hi, > > > > I'd like to propose eliminating packaging of Go libs. > > For my own go application I use the ports mechanism to specify specific > versions of dependencies and it would only have been tested with those; > if forces to use an older version it would likely fail as the APIs on > some libs have changed quite a lot. > > So I personally see no need to have any go dependencies in the ports > tree. I currently like the idea of having all the go dependencies > statically linked and only few external "C" libs as dynamic links as it > makes packaging and deployment very quick. > > > > > Almost every Go app is developed with a different version of any given > > lib than what another Go app might use. Forcing a Go app to use a > > different version than what upstream might have chosen is error prone > > at best and likely to produce a build that's unsupported upstream. So > > for the packaged libs to even be useful, we would have to have as many > > versions of each lib as there are consumers, or nearly as many. > > > > Further, best practice in the Go community is for Go apps to vendor > > all their dependencies and almost all apps do that. This is the > > reason most Go apps use different versions of it's libs. > > > > So to me, packaging Go libs doesn't make sense and I think we should > > remove the Go libs from ports. > > > > Existing ports which use the Go libs should be updated to not use the > > Go lib ports by doing one of these, in priority order: > > > > * Converted to using vendored deps included with the package source if > > possible (preferred) > > * Fetching the versions of deps specified by upstream (in the case of > > vendor.json) > > * As a last resort (deps are not included nor versions specified > > exactly) fetching versions of deps available at the time of upstream > > development > > > > Further, documentation should be added to the Porters Handbook saying > > that we don't package Go libs and portlint should be updated to check > > for installing files in GO_SRCDIR and GO_LIBDIR (exceot lang/go*). > > > > For reference, here's the list of Go lib ports that I found at the > > moment: > > > > archivers/go-compress > > databases/gomdb > > databases/gosqlite3 > > databases/levigo > > databases/radix.v2 > > databases/redigo > > devel/go-bayesian > > devel/go-cobra > > devel/go-codec > > devel/go-cpuid > > devel/go-crc32 > > devel/go-faker > > devel/go-form > > devel/go-go.uuid > > devel/go-goregen > > devel/go-hashicorp-logutils > > devel/go-json-rest > > devel/go-logrus > > devel/go-metrics > > devel/go-nuid > > devel/go-pflag > > devel/go-protobuf > > devel/go-raw > > devel/go-runewidth > > devel/go-slices > > devel/go-sql-driver > > devel/go-uuid > > devel/go-yaml > > devel/goprotobuf > > net/go-amqp > > net/go-geoip > > net/go-httppath > > net/go-httptreemux > > net/go-nats > > net/go.net > > security/go.crypto > > security/goptlib > > textproc/go.text > > www/go-fasthttp > > www/webgo > > > > Does anyone have any objection or reasoning why this doesn't make > > sense? > > > > Thanks, > > Steve > > > > > -- > Best Regards. > Christopher Hall. > _______________________________________________ > freebsd-ports@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-ports > To unsubscribe, send any mail to "freebsd-ports-unsubscribe@freebsd.org" >