Re: BSD awk bug ?

2017-08-15 Thread Tomoya Tabuchi
On Wed, Aug 16, 2017 at 10:14:46AM +0900, KIRIYAMA Kazuhiko wrote:
> admin@tbedfpc:~/tmp % ll
> total 12
> -rw-r--r--  1 admin  admin  235 Aug 16 10:01 regex-1.sh
> -rw-r--r--  1 admin  admin  236 Aug 16 10:01 regex-2.sh
> -rw-r--r--  1 admin  admin  260 Aug 16 10:01 regex.sh
> admin@tbedfpc:~/tmp % cat regex.sh 
> #!/bin/sh
> 
> data='1 2 3 4 5 6
> 1 2 3 4 5
> 1 2 3 4 5 6
> 1 2 3 4 5 6
> 1 2 3 4
> 1 2 3'
> 
> IFS=$'\n'
> for datum in $data; do
> if echo "$datum" | egrep -q  '^([^[:space:]]+[[:space:]]+){5}'; then
> echo "$datum"
> else
> echo "Not 6 components! : \"$datum\""
> fi
> done
> admin@tbedfpc:~/tmp % sh ./regex.sh 
> 1 2 3 4 5 6
> Not 6 components! : "1 2 3 4 5"
> 1 2 3 4 5 6
> 1 2 3 4 5 6
> Not 6 components! : "1 2 3 4"
> Not 6 components! : "1 2 3"
> admin@tbedfpc:~/tmp % cat regex-1.sh 
> #!/bin/sh
> 
> _f_awk='
> {
> if ($0 ~ /^([^[:space:]]+[[:space:]]+){5}/) {
> print $0
> } else {
> print "Not 6 components! : \"" $0 "\""
> }
> }'
> 
> data='1 2 3 4 5 6
> 1 2 3 4 5
> 1 2 3 4 5 6
> 1 2 3 4 5 6
> 1 2 3 4
> 1 2 3'
> 
> echo "$data" | awk "$_f_awk"
> admin@tbedfpc:~/tmp % sh ./regex-1.sh 
> Not 6 components! : "1 2 3 4 5 6"
> Not 6 components! : "1 2 3 4 5"
> Not 6 components! : "1 2 3 4 5 6"
> Not 6 components! : "1 2 3 4 5 6"
> Not 6 components! : "1 2 3 4"
> Not 6 components! : "1 2 3"
> admin@tbedfpc:~/tmp % cat regex-2.sh
> #!/bin/sh
> 
> _f_awk='
> {
> if ($0 ~ /^([^[:space:]]+[[:space:]]+){5}/) {
> print $0
> } else {
> print "Not 6 components! : \"" $0 "\""
> }
> }'
> 
> data='1 2 3 4 5 6
> 1 2 3 4 5
> 1 2 3 4 5 6
> 1 2 3 4 5 6
> 1 2 3 4
> 1 2 3'
> 
> echo "$data" | gawk "$_f_awk"
> admin@tbedfpc:~/tmp % sh ./regex-2.sh
> 1 2 3 4 5 6
> Not 6 components! : "1 2 3 4 5"
> 1 2 3 4 5 6
> 1 2 3 4 5 6
> Not 6 components! : "1 2 3 4"
> Not 6 components! : "1 2 3"
> admin@tbedfpc:~/tmp % uname -a
> FreeBSD tbedfpc 12.0-CURRENT FreeBSD 12.0-CURRENT #0 r321597: Thu Jul 27 
> 12:30:57 UTC 2017 root@tbedfc:/usr/obj/usr/src/sys/GENERIC  amd64
> admin@tbedfpc:~/tmp % pkg info -aI|grep gawk
> gawk-4.1.4_1   GNU version of Awk
> admin@tbedfpc:~/tmp % 
> 
> 
> Is this the BSD awk (/usr/bin/awk) bug ?
> 
> ---
> KIRIYAMA Kazuhiko
> ___
> freebsd-current@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-current
> To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"

Hello Kiriyama-san,

The man page awk(1) says that {m,n} matcning is not supported. The "{5}"
part matches the literal sequence of characters it's made out of, I suppose.

Someone please correct me if I'm wrong.

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


Re: Problem with pkg

2017-02-27 Thread Tomoya Tabuchi
On Mon, Feb 27, 2017 at 01:02:23PM +, Filippo Moretti wrote:
> After a blackout caused by my wife I only get a few pkg shown with the 
> command pkg info while they should be hundreds.I also get this error message 
> when trying to install packages by pkg installpkg: Repository FreeBSD load 
> error: access repo file(/var/db/pkg/repo-FreeBSD.sqlite) failed: No such file 
> or directory(I do have a file name local.sqlite)Is there a way to recover the 
> pkg database or should I reinstall the OS.Filippo
> 
> 
> ___
> freebsd-current@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-current
> To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"

Hello,

I have a similar problem.
pkg(8) tells me to do a `pkg update', and when I do that I get the following.

Updating FreeBSD repository catalogue...
pkg: Repository FreeBSD load error: access repo
file(/var/db/pkg/repo-FreeBSD.sqlite) failed: No such file or directory
meta.txz : 100%  944 B 0.9kB/s
00:01
packagesite.txz  : 100%6 MiB 986.3kB/s
00:06
pkg: rsa verify failed: error:04091077:rsa routines:INT_RSA_VERIFY:wrong
signature length
pkg: No trusted certificate has been used to sign the repository
Unable to update repository FreeBSD
Error updating repositories!

I am on r314247 and the version of pkg(8) is 1.10.0.

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


Re: gfx-next update: drm-4.8-rc2 tagged in drm-next

2016-08-17 Thread Tomoya Tabuchi
Hello

I'd like to know what 'IFCed to HEAD' means. I'm quite new to FreeBSD.

Thank you for your work. Looking forward to running FreeBSD on my laptop
with graphics.

Thanks in advance.

Tomoya

On Tue, Aug 16, 2016 at 12:12:44AM -0700, Matthew Macy wrote:
> As of this moment sys/dev/drm in the drm-next tree is sync with 
> https://github.com/torvalds/linux drivers/gpu/drm (albeit only for the subset 
> of drivers that FreeBSD supports -  i915, radeon, and amdgpu). I feel this is 
> a bit of a milestone as it means that it is possible that in the future 
> graphics support on FreeBSD could proceed in lockstep with Linux. 
> 
> In addition I have IFCed both drm-next-4.6 and drm-next to HEAD as of today.
> 
> Once I'm done working on Kaby Lake support I intend to get radeon and amdgpu 
> to the point where they work as well as i915. Following that we'll need to 
> spend some time resolving general correctness issues.
> 
> -M
> 
> ___
> freebsd-...@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-x11
> To unsubscribe, send any mail to "freebsd-x11-unsubscr...@freebsd.org"
___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"