Re: How to get pkg to recognize local repository?

2017-07-19 Thread Adam Weinberger
> On 17 Jul, 2017, at 20:33, Thomas Mueller  wrote:
> 
> Excerpt from Adam Weinberger:
> 
>> myfirstrepo: {
>>url: file:///path/to/first/repo,
>>priority: 99
>> },
>> mysecondrepo: {
>>url: file:///path/to/second/repo,
>>priority: 98
>> }

Hi Tom, sorry I completely missed your reply.

> I suppose priority 99 would take priority over priority 98?

Correct. 100 is highest priority, 0 is lowest. Take a look at the pkg.conf 
manage.

> In normal English usage, first priority or priority one is higher than 
> priority two.
> 
> Do you need the comma after the closing brace after myfirstrepo?

ucl is pretty forgiving.

> I suppose myfirst repo and mysecondrepo are both in the same .conf file?

They don't have to be. Personally I keep them in separate files.

/usr/local/etc/pkg/repos/universal.conf
  priority: 80
/usr/local/etc/pkg/repos/local.conf
  priority: 90

# Adam


-- 
Adam Weinberger
ad...@adamw.org
https://www.adamw.org

___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: How to get pkg to recognize local repository?

2017-07-18 Thread Thomas Mueller
On Tue, 18 Jul 2017 02:33:22 +
"Thomas Mueller"  wrote:

> I suppose priority 99 would take priority over priority 98?

> In normal English usage, first priority or priority one is higher
> than priority two.

> Do you need the comma after the closing brace after myfirstrepo?

> I suppose myfirst repo and mysecondrepo are both in the same .conf
> file?

Bob Eager responded:

> This isn't well (or, at least, transparently) documented. However, if
> you do 'man pkg.conf' and read down, it eventually tells you the syntax
> of a repo file.
 
> I've always put them one per file, with a name that reflects that repo.

"man pkg.conf" says individual repository configuration files are processed in 
alphabetical order.

But according to the man page, one configuration file can specify more than one 
repository.

I guess I'll need to do some trial and error, given the confusing nature of the 
documentation.

I still want to get rid of the old no-longer-usable packages.  All I can think 
of now is Midnight Commander (mc) from NetBSD.

There ought to be a convenient way to remove outdated packages from a repo,  Or 
maybe there is but not documented, or at least not clearly documented?

I also want to look at how NetBSD pkgsrc defines/configures a repo so as to 
compare to FreeBSD.

Tom

___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: How to get pkg to recognize local repository?

2017-07-18 Thread Boris Samorodov

18.07.2017 05:33, Thomas Mueller пишет:


This looks like it might help, but PKG-REPOSITORY and FETCH have to be 
lower-case, won't work with capital letters.


That's an old unix tradition. PKG-REPOSITORY(5) and FETCH(3) mean
that one should use "man 5 pkg-repository" and "man 3 fetch" to
get the needed info.

PS. If you try the first command, at the very firts line you'll get:
---
PKG-REPOSITORY(5)FreeBSD File Formats Manual PKG-REPOSITORY(5)
---

HTH
--
WBR, Boris Samorodov (bsam)
FreeBSD Committer, http://www.FreeBSD.org The Power To Serve
___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"

Re: How to get pkg to recognize local repository?

2017-07-18 Thread Bob Eager
On Tue, 18 Jul 2017 02:33:22 +
"Thomas Mueller"  wrote:

> I suppose priority 99 would take priority over priority 98?
> 
> In normal English usage, first priority or priority one is higher
> than priority two.
> 
> Do you need the comma after the closing brace after myfirstrepo?
> 
> I suppose myfirst repo and mysecondrepo are both in the same .conf
> file?

This isn't well (or, at least, transparently) documented. However, if
you do 'man pkg.conf' and read down, it eventually tells you the syntax
of a repo file.

I've always put them one per file, with a name that reflects that repo.
___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: How to get pkg to recognize local repository?

2017-07-17 Thread Thomas Mueller
from Franco Fichtner:

# pkg repo /mnt/usr/packages

Would that put meta.txz and other stuff in /usr/packages ?

I could do that either by nfs (with /mnt) or directly on that computer (without 
/mnt).

But I have all the old stuff I no longer want, would not run because of shared 
libraries out of sync: 223 packages I didn't show.  How to delete? 

Or more generally, how to delete old packages in /usr/packages/All in a 
reasonable time?  Midnight Commander, which I recently installed on NetBSD but 
have not yet used?

> 17.07.2017 08:10, Thomas Mueller пишет:

> > How do I get pkg to recognize a local repository

> It is documented at PKG-REPOSITORY(5) .  [1]

> > What is the proper URL or format for a file name/directory?  Is it 
> > necessary to precede with URL: or what do I have to do to make it look like 
> > a repository?


> It is mentioned at [1]: the scheme is documented at FETCH(3) .


> HTH

> WBR, Boris Samorodov (bsam)

This looks like it might help, but PKG-REPOSITORY and FETCH have to be 
lower-case, won't work with capital letters.

Excerpt from Adam Weinberger:

> myfirstrepo: {
> url: file:///path/to/first/repo,
> priority: 99
> },
> mysecondrepo: {
> url: file:///path/to/second/repo,
> priority: 98
> }

I suppose priority 99 would take priority over priority 98?

In normal English usage, first priority or priority one is higher than priority 
two.

Do you need the comma after the closing brace after myfirstrepo?

I suppose myfirst repo and mysecondrepo are both in the same .conf file?


Tom

___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"

Re: How to get pkg to recognize local repository?

2017-07-17 Thread Adam Weinberger
> On 17 Jul, 2017, at 11:13, Patrick Powell  wrote:
> 
> On 07/16/17 22:21, Matthias Apitz wrote:
>> El día lunes, julio 17, 2017 a las 05:10:06a. m. +, Thomas Mueller 
>> escribió:
>> 
>>> How do I get pkg to recognize a local repository such as 
>>> /mnt/usr/packages/All, or does pkg only recognize remote repositories?
>>> 
>>> ...
>> I use:
>> 
>> $ ls -l /usr/local/etc/pkg/repos/*.conf
>> -rw-r--r--  1 root  wheel  35 12 mar.  11:05 
>> /usr/local/etc/pkg/repos/FreeBSD.conf
>> -rw-r--r--  1 root  wheel  96 12 mar.  11:05 
>> /usr/local/etc/pkg/repos/myrepo.conf
>> $ cat /usr/local/etc/pkg/repos/FreeBSD.conf
>>  FreeBSD: { enabled: no }
>> 
>> $ cat /usr/local/etc/pkg/repos/myrepo.conf
>> 
>> FreeBSD: {
>> url: "file:///usr/local/PKGDIR.20170304",
>> enabled: true,
>> }
>> 
>> HIH
>> 
>>  matthias
> 
> Just out of curiosity (and because I might want to do this) how can you 
> specify two (or more) repositories
> and have them searched in some order.  For example,  you might have a local 
> respository with some
> ports/packages that you are currently debugging/fixing.  You want pkg to 
> search the local respository
> first and then if it does not find the packages to use the default (remote) 
> repository.

myfirstrepo: {
url: file:///path/to/first/repo,
priority: 99
},
mysecondrepo: {
url: file:///path/to/second/repo,
priority: 98
}

# Adam



-- 
Adam Weinberger
ad...@adamw.org
https://www.adamw.org

___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"

Re: How to get pkg to recognize local repository?

2017-07-17 Thread Kurt Jaeger
Hi!

> Just out of curiosity (and because I might want to do this) how can you 
> specify two (or more) repositories
> and have them searched in some order.

Probably by having two or more config files for repos in

/usr/local/etc/pkg/repos/

I don't know how to have preferences in there.

-- 
p...@opsec.eu+49 171 3101372 3 years to go !
___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: How to get pkg to recognize local repository?

2017-07-17 Thread Patrick Powell

On 07/16/17 22:21, Matthias Apitz wrote:

El día lunes, julio 17, 2017 a las 05:10:06a. m. +, Thomas Mueller escribió:


How do I get pkg to recognize a local repository such as /mnt/usr/packages/All, 
or does pkg only recognize remote repositories?

...

I use:

$ ls -l /usr/local/etc/pkg/repos/*.conf
-rw-r--r--  1 root  wheel  35 12 mar.  11:05 
/usr/local/etc/pkg/repos/FreeBSD.conf
-rw-r--r--  1 root  wheel  96 12 mar.  11:05 
/usr/local/etc/pkg/repos/myrepo.conf
$ cat /usr/local/etc/pkg/repos/FreeBSD.conf
 
 FreeBSD: { enabled: no }


$ cat /usr/local/etc/pkg/repos/myrepo.conf

 FreeBSD: {
 url: "file:///usr/local/PKGDIR.20170304",
 enabled: true,
 }

HIH

matthias


Just out of curiosity (and because I might want to do this) how can you 
specify two (or more) repositories
and have them searched in some order.  For example,  you might have a 
local respository with some
ports/packages that you are currently debugging/fixing.  You want pkg to 
search the local respository
first and then if it does not find the packages to use the default 
(remote) repository.


--
Patrick Powell Astart Technologies
papow...@astart.com1530 Jamacha Rd, Suite X
Network and System San Diego, CA 92019
  Consulting   Cell 858-518-7581 FAX 858-751-2435
Web: papowell at astart dot com

___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"

Re: How to get pkg to recognize local repository?

2017-07-17 Thread Franco Fichtner

> On 17. Jul 2017, at 8:44 AM, Thomas Mueller  wrote:
> 
> What meta files?  There is a metamail-2.7_11.txz, but I don't think that's 
> what you meant.

The files digests.txz, meta.txz and packagesite.txz, like this...

https://pkg.opnsense.org/FreeBSD:11:amd64/17.1/latest/

> 
> On the drive I was trying to install from, 
> ls -l /mnt/usr/packages shows
> 
> total 12
> drwxr-xr-x  2 root  wheel  7680 Jun 12 07:34 All
> drwxr-xr-x  2 root  wheel   512 Jun 12 04:41 Latest

# pkg repo /mnt/usr/packages


Cheers,
Franco
___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: How to get pkg to recognize local repository?

2017-07-17 Thread Thomas Mueller
> > On 17. Jul 2017, at 7:10 AM, Thomas Mueller  wrote:

> > pkg-static: Ignoring bad configuration entry in 
> > /usr/local/etc/pkg/repos/mytemprepo.conf: "file:///mnt/usr/packages/All"
> > pkg-static: Warning: Major OS version upgrade detected.  Running 
> > "pkg-static install -f pkg" recommended
> > No active remote repositories configured.

> You want to point to file:///mnt/usr/packages instead, it should work given
> the repository meta files are in there.


> Cheers,
> Franco

What meta files?  There is a metamail-2.7_11.txz, but I don't think that's what 
you meant.

On the drive I was trying to install from, 
ls -l /mnt/usr/packages shows

total 12
drwxr-xr-x  2 root  wheel  7680 Jun 12 07:34 All
drwxr-xr-x  2 root  wheel   512 Jun 12 04:41 Latest

Latest just contains 

lrwxr-xr-x  1 root  wheel  21 Jun 12 04:41 pkg.txz -> ../All/pkg-1.10.1.txz

while ls -rtl /mnt/usr/packages/All shows no meta files.

ls -l /mnt/var/synth/live_packages shows

total 20
drwxr-xr-x  2 root  wheel   512 Jul  2 06:39 All
drwxr-xr-x  2 root  wheel   512 Jul  2 06:04 Latest
-rw-r--r--  1 root  wheel   588 Jul  2 06:25 digests.txz
-rw-r--r--  1 root  wheel   264 Jul  2 06:25 meta.txz
-rw-r--r--  1 root  wheel  1880 Jul  2 06:25 packagesite.txz

and
ls -l /mnt/var/synth/live_packages/All  shows

total 3200
-rw-r--r--  1 root  wheel98876 Jul  2 06:04 ccache-3.3.4_3.txz
-rw-r--r--  1 root  wheel 5312 Jul  2 06:04 indexinfo-0.2.6.txz
-rw-r--r--  1 root  wheel16392 Jul  2 06:39 libsigsegv-2.11.txz
-rw-r--r--  1 root  wheel  2984472 Jul  2 06:04 pkg-1.10.1.txz
-rw-r--r--  1 root  wheel53000 Jul  2 06:39 pkgconf-1.3.7,1.txz
-rw-r--r--  1 root  wheel42548 Jul  2 06:04 portmaster-3.17.10.txz

That is not all that is installed; "synth upgrade-system" only succeeded on a 
few packages before crashing (system crash and reboot, I tried a second time 
with same crash).

ls -rtl /mnt/usr/packages/All shows (not including old deleted packages):

-rw-r--r--  1 root  wheel   2985132 Jun 12 04:41 pkg-1.10.1.txz
-rw-r--r--  1 root  wheel 42552 Jun 12 04:41 portmaster-3.17.10.txz
-rw-r--r--  1 root  wheel616476 Jun 12 04:46 libiconv-1.14_10.txz
-rw-r--r--  1 root  wheel   504 Jun 12 05:08 gettext-0.19.8.1.txz
-rw-r--r--  1 root  wheel 98916 Jun 12 06:02 ccache-3.3.4_3.txz
-rw-r--r--  1 root  wheel  5312 Jun 12 06:02 indexinfo-0.2.6.txz
-rw-r--r--  1 root  wheel152516 Jun 12 06:02 gettext-runtime-0.19.8.1_1.txz
-rw-r--r--  1 root  wheel   2329976 Jun 12 06:04 gettext-tools-0.19.8.1.txz
-rw-r--r--  1 root  wheel388288 Jun 12 06:04 gmake-4.2.1_1.txz
-rw-r--r--  1 root  wheel 52988 Jun 12 06:04 pkgconf-1.3.7,1.txz
-rw-r--r--  1 root  wheel   1485748 Jun 12 06:05 ncurses-6.0_3.txz
-rw-r--r--  1 root  wheel 16372 Jun 12 06:05 libsigsegv-2.11.txz
-rw-r--r--  1 root  wheel  1436 Jun 12 06:09 perl5-5.26.0.txz
-rw-r--r--  1 root  wheel 16844 Jun 12 06:09 p5-Locale-gettext-1.07.txz
-rw-r--r--  1 root  wheel139420 Jun 12 06:10 help2man-1.47.4.txz
-rw-r--r--  1 root  wheel   1248316 Jun 12 06:10 texinfo-6.3_2,1.txz
-rw-r--r--  1 root  wheel209540 Jun 12 06:11 m4-1.4.18,1.txz
-rw-r--r--  1 root  wheel515372 Jun 12 06:11 bison-3.0.4,1.txz
-rw-r--r--  1 root  wheel475256 Jun 12 06:13 gmp-6.1.2.txz
-rw-r--r--  1 root  wheel371092 Jun 12 06:14 mpfr-3.1.5_1.txz
-rw-r--r--  1 root  wheel  20079120 Jun 12 06:25 binutils-2.28,1.txz
-rw-r--r--  1 root  wheel 75100 Jun 12 06:25 mpc-1.0.3.txz
-rw-r--r--  1 root  wheel  32102776 Jun 12 07:33 gcc6-aux-20170202_1.txz
-rw-r--r--  1 root  wheel385796 Jun 12 07:34 adacurses-20150808_4.txz
-rw-r--r--  1 root  wheel 21744 Jun 12 07:34 ini_file_manager-03_2.txz
-rw-r--r--  1 root  wheel666432 Jun 12 07:34 synth-1.69.txz

But how would I get those packages copied/installed and see if synth works 
better on the other computer?

from Matthias Apitz:

I use:

> $ ls -l /usr/local/etc/pkg/repos/*.conf
> -rw-r--r--  1 root  wheel  35 12 mar.  11:05 
> /usr/local/etc/pkg/repos/FreeBSD.conf
> -rw-r--r--  1 root  wheel  96 12 mar.  11:05 
> /usr/local/etc/pkg/repos/myrepo.conf
> $ cat /usr/local/etc/pkg/repos/FreeBSD.conf

> FreeBSD: { enabled: no }

> $ cat /usr/local/etc/pkg/repos/myrepo.conf

> FreeBSD: {
> url: "file:///usr/local/PKGDIR.20170304",
> enabled: true,
}

> HIH

> matthias

What is /usr/local/PKGDIR.20170304 , how do you get a file by that name?  

ls -l /mnt/usr/local shows

total 104
drwxr-xr-x   2 root  wheel  16896 Jun 12 07:34 bin
drwxr-xr-x  10 root  wheel   1024 Jul  2 06:01 etc
drwxr-xr-x   6 root  wheel512 Jun 12 07:32 gcc6-aux
drwxr-xr-x   9 root  wheel   2560 Jun 12 07:34 include
drwxr-xr-x   2 root  wheel   1024 Jun 12 06:25 info
drwxr-xr-x  19 root  wheel  32256 Jun 12 07:34 lib
drwxr-xr-x   5 root  wheel512 Jun 12 06:09 libdata
drwxr-xr-x   4 root  wheel   1536 Jun 12 07:34 libexec
drwxr-xr-x   3 root  wheel512 Jun 12 05:39 

Re: How to get pkg to recognize local repository?

2017-07-16 Thread Matthias Apitz
El día lunes, julio 17, 2017 a las 05:10:06a. m. +, Thomas Mueller escribió:

> How do I get pkg to recognize a local repository such as 
> /mnt/usr/packages/All, or does pkg only recognize remote repositories?
> 
> ...

I use:

$ ls -l /usr/local/etc/pkg/repos/*.conf
-rw-r--r--  1 root  wheel  35 12 mar.  11:05 
/usr/local/etc/pkg/repos/FreeBSD.conf
-rw-r--r--  1 root  wheel  96 12 mar.  11:05 
/usr/local/etc/pkg/repos/myrepo.conf
$ cat /usr/local/etc/pkg/repos/FreeBSD.conf

FreeBSD: { enabled: no }

$ cat /usr/local/etc/pkg/repos/myrepo.conf

FreeBSD: {
url: "file:///usr/local/PKGDIR.20170304",
enabled: true,
}

HIH

matthias
-- 
Matthias Apitz, ✉ g...@unixarea.de, ⌂ http://www.unixarea.de/  ☎ 
+49-176-38902045
Public GnuPG key: http://www.unixarea.de/key.pub
8. Mai 1945: Wer nicht feiert hat den Krieg verloren.
8 de mayo de 1945: Quien no festeja perdió la Guerra.
May 8, 1945: Who does not celebrate lost the War.


signature.asc
Description: PGP signature


Re: How to get pkg to recognize local repository?

2017-07-16 Thread Franco Fichtner

> On 17. Jul 2017, at 7:10 AM, Thomas Mueller  wrote:
> 
> pkg-static: Ignoring bad configuration entry in 
> /usr/local/etc/pkg/repos/mytemprepo.conf: "file:///mnt/usr/packages/All"
> pkg-static: Warning: Major OS version upgrade detected.  Running "pkg-static 
> install -f pkg" recommended
> No active remote repositories configured.

You want to point to file:///mnt/usr/packages instead, it should work given
the repository meta files are in there.


Cheers,
Franco
___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


How to get pkg to recognize local repository?

2017-07-16 Thread Thomas Mueller
How do I get pkg to recognize a local repository such as /mnt/usr/packages/All, 
or does pkg only recognize remote repositories?

In this case, /mnt was a mount point for another FreeBSD 11.1-PRERELEASE 
installation from the same svn revision.  Second was installed from the first 
using NFS.

Even env PACKAGEPATH=/mnt/usr/packages/All pkg-static install pkg  didn't work.

pkg-static: Ignoring bad configuration entry in 
/usr/local/etc/pkg/repos/mytemprepo.conf: "file:///mnt/usr/packages/All"
pkg-static: Warning: Major OS version upgrade detected.  Running "pkg-static 
install -f pkg" recommended
No active remote repositories configured.

What is the proper URL or format for a file name/directory?  Is it necessary to 
precede with URL: or what do I have to do to make it look like a repository?  I 
have been unable to get anything to work.

While it would be easier to just build the packages again, I would like to know 
how to install from one computer or installation to another without recompiling.

Tom

___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"