On Sat, Jul 07, 2018 at 03:52:44PM +0100, Tom Smyth wrote:

> Hello Nan,
> you need to set the PKG_path as Stuart suggested to install packages using
> 
> pkg_add command
> 
> for example to use fastly cdn  mirror you would set your pkg_path variable as
> shown below
> 
> export PKG_PATH=https://fastly.cdn.openbsd.org/pub/OpenBSD/$(uname
> -r)/packages/$(uname -p)/
> 
> /etc/installurl  file is for the syspatch utility to install binary
> patches for the release

Wrong. installurl *is* used by pkg_add. Read the man page.

        -Otto
> 
> 
> 
> if you are using current ... Packages  are less straight forward as
> packages and current
> are modified regularly updated
> so if you go to install a package from today on a current snapshot from 1 week
> ago it is not guaranteed to work
> 
> i believe there are few ways around this
> 1) install the packages that you expect to use on current as soon as possible
> after install
> 2) if you must use that version of current for some reason ... when 
> downloading
> the current install iso / install image, download the contents of the
> entire package
> directory for current also. (on the same day )  your millage on this
> will vary  depending
> on what work is being done on the tree at the time
> 
> and if anyone else uses a  better way id love to know also
> 
> 
> I hope this helps
> 
> 
> On 7 July 2018 at 15:26, Nan Xiao <xiaonan830...@gmail.com> wrote:
> > HI Stuart,
> >
> > Thanks for your reply!
> >
> > I don't set PKG_PATH environment.
> >
> > Yes, it seems I installed the current package:
> > $ ls -l /usr/local/bin/egdb
> > -rwxr-xr-x  1 root  bin  10040410 Jun 28 19:03 /usr/local/bin/egdb
> >
> > But I can't remember what I have done. I can only remember I modified
> > /etc/installurl before.
> >
> > Thanks!
> > Best Regards
> > Nan Xiao
> >
> >
> > On Sat, Jul 7, 2018 at 8:23 PM, Stuart Henderson <s...@spacehopper.org> 
> > wrote:
> >> On 2018-07-07, Nan Xiao <xiaonan830...@gmail.com> wrote:
> >>> Hi Philip,
> >>>
> >>> Thanks very much for your time and effort!
> >>>
> >>> The following is the command output:
> >>>
> >>> $ readelf -Wl /usr/local/bin/egdb | awk '/RANDOM/{print ($5+0)/1024}'
> >>> 88.4844
> >>>
> >>> The same as yours.
> >>
> >> That is from -current.
> >>
> >>> Honestly, I am not sure whether the package is for -stable or -current.
> >>>
> >>> After installation, I just add following config in /etc/installurl:
> >>> $ cat /etc/installurl
> >>> https://ftp.openbsd.org/pub/OpenBSD
> >>>
> >>> Then I use "pkg_add -u" sometimes. Doesn't
> >>> https://ftp.openbsd.org/pub/OpenBSD guarantee it selects correct
> >>> packages? Or I miss something?
> >>
> >> Do you have PKG_PATH set in the environment?
> >>
> >> Whatever the reason, it looks like you have a -current version of the
> >> gdb package installed.
> >>
> >> The one in 6.3 should look like this:
> >>
> >> $ ls -l /usr/local/bin/egdb
> >> -rwxr-xr-x  1 root  bin  9452688 Mar 28 00:40 /usr/local/bin/egdb
> >>
> >> $ readelf -Wl /usr/local/bin/egdb | awk '/RANDOM/{print($5+0)/1024}'
> >> 0.0078125
> >>
> >>
> >
> 
> 
> 
> -- 
> Kindest regards,
> Tom Smyth
> 
> Mobile: +353 87 6193172
> The information contained in this E-mail is intended only for the
> confidential use of the named recipient. If the reader of this message
> is not the intended recipient or the person responsible for
> delivering it to the recipient, you are hereby notified that you have
> received this communication in error and that any review,
> dissemination or copying of this communication is strictly prohibited.
> If you have received this in error, please notify the sender
> immediately by telephone at the number above and erase the message
> You are requested to carry out your own virus check before
> opening any attachment.

Reply via email to