Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k4yqS-000287-FR for pljava-dev@arkaria.postgresql.org; Mon, 10 Aug 2020 03:51:32 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1k4yqQ-0002Go-3U for pljava-dev@arkaria.postgresql.org; Mon, 10 Aug 2020 03:51:30 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k4yqP-0002Ga-UK for pljava-dev@lists.postgresql.org; Mon, 10 Aug 2020 03:51:29 +0000 Received: from anastigmatix.net ([68.171.219.55]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k4yqG-0005Aw-35 for pljava-dev@lists.postgresql.org; Mon, 10 Aug 2020 03:51:26 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=anastigmatix.net; s=default; h=Content-Transfer-Encoding:Content-Type: In-Reply-To:MIME-Version:Date:Message-ID:From:Cc:References:To:Subject:Sender :Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=VrH1Qqk2/DtaPo06nMdnpj7iW8SGC0LO2mDvoSHt3GY=; b=mHLZBhJcTow3Af5FLiZqUy8Efy bytxOBylnviwWobNVFm+yWxVhdq2+37+wHYZsr/qhiRqYc44AESvGbX7FyUezTNxOE+6xd3qd5MdW M9BnnZ+AmuEw39LYLr337jImBG3f8BTdnlF8093dCx+huytM4GWuFSXH8bg638EaZlI7Uuzs6xPDc IqC9VTnzh2mz542HIksS6QoO6uQHZUBhFuW9xHIxW2OtTKBFtN8Q0LctPJM84vyDlOaIkSq9DtVPA aJdE7oHxjgKJZ8v+WxkTsLKg3fMPVbjJT/S8f/bl53m0z4SKpxHjpdAnGHEtGHCaNUkHqzJcgaQ6W vTyTZKhA==; Received: from [184.19.31.139] (port=58808) by bay.acenet.us with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1k4yqC-00F0zP-G4; Sun, 09 Aug 2020 23:51:16 -0400 Subject: Re: PL/Java new build plugin To: Kartik Ohri References: <5F230337.3040406@anastigmatix.net> <5F232EBB.9030208@anastigmatix.net> <5F278CCE.1090006@anastigmatix.net> <5F2897AF.9040909@anastigmatix.net> <5F2A29E4.2000803@anastigmatix.net> <5F2EB313.8090706@anastigmatix.net> <5F2EE97B.1030108@anastigmatix.net> <5F30B425.4020402@anastigmatix.net> Cc: pljava-dev@lists.postgresql.org From: Chapman Flack X-Enigmail-Draft-Status: N1110 Message-ID: <5F30C433.3070906@anastigmatix.net> Date: Sun, 9 Aug 2020 23:51:15 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.7.0 MIME-Version: 1.0 In-Reply-To: <5F30B425.4020402@anastigmatix.net> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-OutGoing-Spam-Status: No, score=-95.0 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - bay.acenet.us X-AntiAbuse: Original Domain - lists.postgresql.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - anastigmatix.net X-Get-Message-Sender-Via: bay.acenet.us: authenticated_id: chap@anastigmatix.net X-Authenticated-Sender: bay.acenet.us: chap@anastigmatix.net X-Source: X-Source-Args: X-Source-Dir: X-From-Rewrite: unmodified, already matched List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 08/09/20 22:42, Chapman Flack wrote: > What would need to be written in Java could be pretty minimal really, > just whatever turns out to make writing JavaScript recipes easy. It > should probably have already collected the CC/LD/CFLAGS/etc. values, > and pass them to the JavaScript as a nice map. On second thought, I don't even think that's worth doing in Java. We already have script calling getPgConfigProperty. If the script block started with some lines like: var CFLAGS = getPgConfigList("--cflags"); var LDFLAGS = ... ... it would be right there, clear, easy to read, hard to beat any other way. If there were more than one native submodule in PL/Java needing to be compiled, it might be worth factoring that out to avoid duplication. But there is only the one, so I think the advantage falls on the side of having the logic visible and accessible. Regards, -Chap