On 2019/08/24 10:02, Gilles Chehade wrote:
> On Sat, Aug 24, 2019 at 06:49:59AM +0200, Martijn van Duren wrote:
> > On 8/24/19 6:07 AM, Martijn van Duren wrote:
> > > Briefly discussed with gilles@.
> > > 
> > > I would like to move the filters to libexec/smtpd for two reasons.
> > > 1) filters are not commandline applications and I don't want them in my
> > >    $PATH.
> > > 2) opensmtpd-extras already used this location, so it's only consistent
> > >    to install there as well.
> > > 
> > > Diff below works for me and based on go.port.mk I don't see any other
> > > way to change the install directory (except for changing go.port.mk)
> > > 
> > > OK?
> > > 
> > > martijn@
> > > 
> > Missed revision bump...
> > 
> 
> ok with the idea but I'm not comfortable enough with ports to know
> if the way you did is the proper way, ports newbie here :-)

I think this should use its own do-install target rather than override
MODGO_INSTALL_TARGET.


> 
> > Index: opensmtpd-filter-rspamd/Makefile
> > ===================================================================
> > RCS file: /cvs/ports/mail/opensmtpd-filter-rspamd/Makefile,v
> > retrieving revision 1.1.1.1
> > diff -u -p -r1.1.1.1 Makefile
> > --- opensmtpd-filter-rspamd/Makefile        13 Aug 2019 18:40:10 -0000      
> > 1.1.1.1
> > +++ opensmtpd-filter-rspamd/Makefile        24 Aug 2019 04:49:48 -0000
> > @@ -3,6 +3,7 @@
> >  COMMENT =  rspamd integration to the OpenSMTPD daemon
> >  
> >  V =                0.1.0
> > +REVISION = 0
> >  DISTNAME = filter-rspamd-${V}
> >  
> >  CATEGORIES =       mail
> > @@ -23,3 +24,7 @@ NO_TEST = Yes
> >  ALL_TARGET =       filter-rspamd
> >  
> >  .include <bsd.port.mk>
> > +
> > +MODGO_INSTALL_TARGET =  ${INSTALL_PROGRAM_DIR} ${PREFIX}/libexec/smtpd && \
> > +                   ${INSTALL_PROGRAM} ${MODGO_WORKSPACE}/bin/* \
> > +                                ${PREFIX}/libexec/smtpd;
> > Index: opensmtpd-filter-rspamd/pkg/PLIST
> > ===================================================================
> > RCS file: /cvs/ports/mail/opensmtpd-filter-rspamd/pkg/PLIST,v
> > retrieving revision 1.1.1.1
> > diff -u -p -r1.1.1.1 PLIST
> > --- opensmtpd-filter-rspamd/pkg/PLIST       13 Aug 2019 18:40:10 -0000      
> > 1.1.1.1
> > +++ opensmtpd-filter-rspamd/pkg/PLIST       24 Aug 2019 04:49:48 -0000
> > @@ -1,3 +1,4 @@
> >  @comment $OpenBSD: PLIST,v 1.1.1.1 2019/08/13 18:40:10 gilles Exp $
> > -@bin bin/filter-rspamd
> > +libexec/smtpd/
> > +@bin libexec/smtpd/filter-rspamd
> >  share/doc/pkg-readmes/${PKGSTEM}
> > Index: opensmtpd-filter-rspamd/pkg/README
> > ===================================================================
> > RCS file: /cvs/ports/mail/opensmtpd-filter-rspamd/pkg/README,v
> > retrieving revision 1.1.1.1
> > diff -u -p -r1.1.1.1 README
> > --- opensmtpd-filter-rspamd/pkg/README      13 Aug 2019 18:40:10 -0000      
> > 1.1.1.1
> > +++ opensmtpd-filter-rspamd/pkg/README      24 Aug 2019 04:49:48 -0000
> > @@ -8,7 +8,7 @@ To use filter-rspamd, you must declare i
> >  
> >  Edit the /etc/mail/smtpd.conf file to declare the filter:
> >  
> > -  filter "rspamd" proc-exec "${PREFIX}/bin/filter-rspamd"
> > +  filter "rspamd" proc-exec "${PREFIX}/libexec/smtpd/filter-rspamd"
> >  
> >  Then add the filter to each listener that should be filtered:
> >  
> > Index: opensmtpd-filter-senderscore/Makefile
> > ===================================================================
> > RCS file: /cvs/ports/mail/opensmtpd-filter-senderscore/Makefile,v
> > retrieving revision 1.1.1.1
> > diff -u -p -r1.1.1.1 Makefile
> > --- opensmtpd-filter-senderscore/Makefile   19 Aug 2019 21:21:17 -0000      
> > 1.1.1.1
> > +++ opensmtpd-filter-senderscore/Makefile   24 Aug 2019 04:49:48 -0000
> > @@ -3,6 +3,7 @@
> >  COMMENT =  SenderScore integration to the OpenSMTPD daemon
> >  
> >  V =                0.1.0
> > +REVISION = 0
> >  DISTNAME = filter-senderscore-${V}
> >  
> >  CATEGORIES =       mail
> > @@ -23,3 +24,7 @@ NO_TEST = Yes
> >  ALL_TARGET =       filter-senderscore
> >  
> >  .include <bsd.port.mk>
> > +
> > +MODGO_INSTALL_TARGET =  ${INSTALL_PROGRAM_DIR} ${PREFIX}/libexec/smtpd && \
> > +                   ${INSTALL_PROGRAM} ${MODGO_WORKSPACE}/bin/* \
> > +                                ${PREFIX}/libexec/smtpd;
> > Index: opensmtpd-filter-senderscore/pkg/PLIST
> > ===================================================================
> > RCS file: /cvs/ports/mail/opensmtpd-filter-senderscore/pkg/PLIST,v
> > retrieving revision 1.1.1.1
> > diff -u -p -r1.1.1.1 PLIST
> > --- opensmtpd-filter-senderscore/pkg/PLIST  19 Aug 2019 21:21:17 -0000      
> > 1.1.1.1
> > +++ opensmtpd-filter-senderscore/pkg/PLIST  24 Aug 2019 04:49:48 -0000
> > @@ -1,3 +1,4 @@
> >  @comment $OpenBSD: PLIST,v 1.1.1.1 2019/08/19 21:21:17 gilles Exp $
> > -@bin bin/filter-senderscore
> > +libexec/smtpd/
> > +@bin libexec/smtpd/filter-senderscore
> >  share/doc/pkg-readmes/${PKGSTEM}
> > Index: opensmtpd-filter-senderscore/pkg/README
> > ===================================================================
> > RCS file: /cvs/ports/mail/opensmtpd-filter-senderscore/pkg/README,v
> > retrieving revision 1.1.1.1
> > diff -u -p -r1.1.1.1 README
> > --- opensmtpd-filter-senderscore/pkg/README 19 Aug 2019 21:21:17 -0000      
> > 1.1.1.1
> > +++ opensmtpd-filter-senderscore/pkg/README 24 Aug 2019 04:49:48 -0000
> > @@ -9,7 +9,7 @@ To use filter-senderscore, you must decl
> >  Edit the /etc/mail/smtpd.conf file to declare the filter:
> >  
> >    filter "senderscore" \
> > -    proc-exec "${PREFIX}/bin/filter-senderscore [...]"
> > +    proc-exec "${PREFIX}/libexec/smtpd/filter-senderscore [...]"
> >  
> >  The following options may be passed to filter-senderscore:
> >  
> > 
> 
> -- 
> Gilles Chehade                                                       @poolpOrg
> 
> https://www.poolp.org            patreon: https://www.patreon.com/gilles
> 

Reply via email to