Re: install default or latest version of php with pkg
Andriy Gapon <[email protected]>
| Newsgroups | gmane.os.freebsd.devel.ports |
|---|---|
| Message-ID | <[email protected]> |
On 14/10/2025 19:45, Moin Rahman wrote: > > >> On Oct 14, 2025, at 18:36, Andriy Gapon <[email protected]> wrote: >> >> >> I am writing a recipe to configure a system for a particular purpose. >> I need to install some version of PHP, doesn't matter much which, but it should be a recent one. E.g., the latest available in ports or the default version. >> I do not want to hardcode any version / prefix like, say, "php83" (because it may be obsolete or unavailable in a few years). >> >> How could this be achieved with pkg? > > I do not know what actually you are trying to do or if I have understood > you correctly. But let's say if I need dokuwiki and I do not want to add > specific version I just do `pkg install www/dokuwiki` which will find > out the required php version suffix and install all the php requirements. > But if you need are using this for a custom application which is not in > the tree and you need to install specific php versions for those then I > believe you are out of options. Yes, it's for something that's not in ports. But maybe it could be put into ports with some effort... Maybe it would be a good idea to have some PHP meta-ports that just install default versions? E.g., for Python there is a python3 package that installs a current default python3.xx version as dependency and there is python package that installs a current default pythonX (python3 currently) as a dependency. -- Andriy Gapon