From owner-svn-src-head@freebsd.org Sat Oct 28 23:57:46 2017 Return-Path: Delivered-To: svn-src-head@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 F3D3AE512C8; Sat, 28 Oct 2017 23:57:45 +0000 (UTC) (envelope-from cse.cem@gmail.com) Received: from mail-io0-f170.google.com (mail-io0-f170.google.com [209.85.223.170]) (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 C3309FAE; Sat, 28 Oct 2017 23:57:45 +0000 (UTC) (envelope-from cse.cem@gmail.com) Received: by mail-io0-f170.google.com with SMTP id 134so19901764ioo.0; Sat, 28 Oct 2017 16:57:45 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:reply-to:in-reply-to:references :from:date:message-id:subject:to:cc:content-transfer-encoding; bh=n15pe59ECFdvzPS6PwcuY0NV5Uda37QsEoswGSzuzuY=; b=puzCYIVtyL6D3T3HQQb+pa0xlaIpygNyTR86uo3oqJKGZ6Ucy3SOlCLJhEbOMCtYsL Vk0c6z0G77E8ctsPLZwYFGM/g8ADHS74KgmSUcAo1aJObASqZEl9TpsylZsnU4TAYFLC eLqHnxLwU5oC+Dfi4hSnbYaXsyVTznFnS50cgXzLn/hnko1uL46T68fC1t0bRY5+9hfu UociihDEq/wWsizIHE1FeXw76LEmmwSSmYkAqTQySFDZkpYTeOSEozqXKz5iDh6OJxMD PW94qv6fgJGYfp6NmCaGJmJX1sa/lyYfXAp1F+mb+IKy988F4qw/tbaTmNsF+8PBzNci nSYQ== X-Gm-Message-State: AMCzsaWYxSqd00EaCx07msD3n62+xTxjKy7nZ4RTP9x0kZ61unB4zhkA nXU59vJb0zSQ5Jq3jKrEj6LhNHxJ X-Google-Smtp-Source: ABhQp+SQt74KFykWs24+hdkkf93LYzyS6NZEGIcTiuZFtInYRXt6q0J3s13acQ9nrPskysopWNFDNA== X-Received: by 10.107.200.207 with SMTP id y198mr6015237iof.157.1509234567583; Sat, 28 Oct 2017 16:49:27 -0700 (PDT) Received: from mail-io0-f172.google.com (mail-io0-f172.google.com. [209.85.223.172]) by smtp.gmail.com with ESMTPSA id m39sm5289280ioo.44.2017.10.28.16.49.27 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 28 Oct 2017 16:49:27 -0700 (PDT) Received: by mail-io0-f172.google.com with SMTP id 134so19885374ioo.0; Sat, 28 Oct 2017 16:49:27 -0700 (PDT) X-Received: by 10.107.16.13 with SMTP id y13mr5727086ioi.117.1509234567338; Sat, 28 Oct 2017 16:49:27 -0700 (PDT) MIME-Version: 1.0 Reply-To: cem@freebsd.org Received: by 10.2.164.130 with HTTP; Sat, 28 Oct 2017 16:49:26 -0700 (PDT) In-Reply-To: <201710281923.v9SJNvE5021346@repo.freebsd.org> References: <201710281923.v9SJNvE5021346@repo.freebsd.org> From: Conrad Meyer Date: Sat, 28 Oct 2017 16:49:26 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: svn commit: r325062 - in head/lib: . libcasper libcasper/libcasper libcasper/services libcasper/services/cap_dns libcasper/services/cap_dns/tests libcasper/services/cap_grp libcasper/services/cap_g... To: Mariusz Zaborski Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 28 Oct 2017 23:57:46 -0000 Hi, On Sat, Oct 28, 2017 at 12:23 PM, Mariusz Zaborski wr= ote: > Author: oshogbo > Date: Sat Oct 28 19:23:57 2017 > New Revision: 325062 > URL: https://svnweb.freebsd.org/changeset/base/325062 > > Log: > Introduce caspermocks. > > The idea behinds mocks is that we don't need to ifdef a lot of code in > tools itself but those defines are hidden in the casper library. > Right now the mocks are implemented as define/inlines functions. > There was a very long discussion how this should be implemented. > This approach has some advantages like we don't need to link to any add= itional > libraries. Unfortunately there are also some disadvantages for example = it is > easy to get library out of sync between two versions of functions or th= at we > need extra define to compile program with casper support. > This isn't an ideal solution but it's good enough for now and should si= mplify > capsicumizing programs. This also doesn't close us any other ways to do= those > mocks and this should evolve in time. > > Discussed with: pjd, emaste, ed, rwatson, bapt, cem, bdrewery > Differential Revision: https://reviews.freebsd.org/D8753 It's worth pointing out "discussed with" here very much does not mean "approved by" =E2=80=94 several of the people mentioned above raised concer= ns with this approach and only one person explicitly supported the change. Best, Conrad