> 1. The port is a daemon. And a daemon needs a rc.d script. So I've
> created one according to
> http://www.openbsd.org/faq/ports/specialtopics.html#RcScripts
> I place it in pkg/udpxy.rc and run make plist. This gives me a
> complain:
>
> make-plist: Bogus element outside of every prefix: /etc/rc.d/udpxy
Yeah, that's one of several known issues with update-plist.
You must not trust its output.
> I optimistically ignore it and continue with make package. But the
> script doesn't get included in the package. What step(s) am I missing to
> get script included into the package?
You need to append the following at the end of the PLIST:
@rcscript ${RCDIR}/udpxy
Beware that running make plist again will remove it...
> 2. I've prepared a patch for the Makefile of the software to prevent
> gzipping of the man pages:
>
> $OpenBSD$
> --- Makefile.orig Mon Jan 5 19:33:29 2015
> +++ Makefile Mon Jan 5 19:34:21 2015
> @@ -182,11 +182,13 @@ install: $(EXEC)
> @cp $(EXEC) $(INSTALLROOT)/bin
> @ls -l $(INSTALLROOT)/bin/$(EXEC)
> @mkdir -p -m 755 $(MANPAGE_DIR)
> - @$(GZIP) -c $(UDPXY_MANPAGE_EN) > $(MANPAGE_DIR)/$(UDPXY_MAN1).gz
> +# @$(GZIP) -c $(UDPXY_MANPAGE_EN) > $(MANPAGE_DIR)/$(UDPXY_MAN1).gz
> + @cp $(UDPXY_MANPAGE_EN) $(MANPAGE_DIR)/$(UDPXY_MAN1)
> ifneq (yes, $(NO_UDPXREC))
> @cp $(UDPXREC) $(INSTALLROOT)/bin/$(UDPXREC)
> @ls -l $(INSTALLROOT)/bin/$(UDPXREC)
> - @$(GZIP) -c $(UDPXREC_MANPAGE_EN) > $(MANPAGE_DIR)/$(UDPXREC_MAN1).gz
> +# @$(GZIP) -c $(UDPXREC_MANPAGE_EN) > $(MANPAGE_DIR)/$(UDPXREC_MAN1).gz
> + @cp $(UDPXREC_MANPAGE_EN) $(MANPAGE_DIR)/$(UDPXREC_MAN1)
> endif
> @echo "Installation of udpxy is complete"
>
> Is this the best/right way to do it?
I think Stuart suggested going with a local do-install target directly within
the port Makefile.
Something like:
do-install:
${INSTALL_PROGRAM} ${WRKBUILD}/.../udpxy ${PREFIX}/bin/udpxy
${INSTALL_MAN} ${WRKBUILD}/.../udpxy.1 ${PREFIX}/man/man1/udpxy.1
etc etc
--
Antoine