Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 23 Apr 2024 18:00:33 +0900
From:      Hiroo Ono <hiroo@oikumene.net>
To:        FreeBSD User <freebsd@walstatt-de.de>
Cc:        FreeBSD Ports <freebsd-ports@freebsd.org>
Subject:   Re: Port maintenance: How to add extra source files to ports tree framework?
Message-ID:  <20240423180033.659a7adc@nowhere.oikumene.ukehi.net>
In-Reply-To: <20240421093704.31ca081f@thor.intern.walstatt.dynvpn.de>
References:  <20240421093704.31ca081f@thor.intern.walstatt.dynvpn.de>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 21 Apr 2024 09:36:37 +0200
FreeBSD User <freebsd@walstatt-de.de> wrote:

> - additionally download the constraints file from another source

Getting several distribution files from  GitHub is documentted in
the Porters' Handbook.
https://docs.freebsd.org/en/books/porters-handbook/makefiles/#makefile-master_sites-github-multiple

The same trick may be applied to other MASTER_SITES. For example:

MASTER_SITES= https://site1.example.com/subdir/:tag1 \
              https://site2.example.com/some-other-dir/:tag2
DISTFILES= file1.tar.gz:tag1 file2.tar.gz:tag2

> - placing the file in the propper staging/wrksrc folder

Both files are extracted under ${WRKKDIR}. If you want to extract
file2.tar.gz to other place, use EXTRACT_ONLY and extract file2.tar.gz
in post-extract target.

> - editing that file according Python requirements

You could use patch files and/or ${REINPLACE_CMD} (sed -i)
(or other programs if you want.)

> - placing the file in pkg-plist

This chapter in the Porter's Handbook might help you.
https://docs.freebsd.org/en/books/porters-handbook/plist/#plist-dynamic

----
Hiroo Ono <hiroo@oikumene.net>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20240423180033.659a7adc>