hns - 日記自動生成システム - Version 2.19.9

先月 2015年10月 来月
1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31
Namazu for hns による簡易全文検索
詳しくは 詳細指定/ヘルプを参照して下さい
検索式:

2015年10月23日(金) 旧暦 [n年日記] [更新:"2015/10/23 15:28:44"]

#1 [pkgsrc] open-vm-tools implicit declaration of 'gethostbyname_r'

gethostbyname_r がないと言われて
/export/WRKOBJDIR/wip-git/open-vm-tools/work/
open-vm-tools-9.4.0-1280544/lib/include/posix.h:215:4: 
error: implicit declaration of function 'gethostbyname_r' 
前にも一度見たことがあるなと思ったが、同じところだった。 2014/03/27

FreeBSD の場合:

FreeBSD はどうしているのかなと思ったら、
/usr/src/lib/libc/net/gethostnamadr.c の中に定義してあって、しかもこれは内部関数で、
    491 int
    492 gethostbyname_r(const char *name, struct hostent *he, char *buffer,
    493     size_t buflen, struct hostent **result, int *h_errnop)
    494 {
    495         res_state statp;
    496
    497         statp = __res_state();
    498         if ((statp->options & RES_INIT) == 0 && res_ninit(statp) == -1) {
    499                 RES_SET_H_ERRNO(statp, NETDB_INTERNAL);
    500                 return (-1);
    501         }
    502         if (statp->options & RES_USE_INET6) {
    503                 if (fakeaddr(name, AF_INET, he, buffer, buflen, statp) == 0) {
    504                         *result = he;
    505                         return (0);
    506                 }
    507                 if (gethostbyname_internal(name, AF_INET6, he, buffer, buflen,
    508                     result, h_errnop, statp) == 0)
    509                         return (0);
    510         }
    511         return (gethostbyname_internal(name, AF_INET, he, buffer, buflen,
    512             result, h_errnop, statp));
    513 }
gethostname から呼出していて、gethostname は reentrant 版になっているらしい
    669 struct hostent *
    670 gethostbyname(const char *name)
    671 {
    672         struct hostdata *hd;
    673         struct hostent *rval;
    674         int ret_h_errno;
    675
    676         if ((hd = __hostdata_init()) == NULL)
    677                 return (NULL);
    678         if (gethostbyname_r(name, &hd->host, hd->data, sizeof(hd->data), &rval,
    679             &ret_h_errno) != 0)
    680                 return (NULL);
    681         return (rval);
    682 }
と思ったら、NetBSD も同様の気がする。


2015年10月19日(月) 旧暦 [n年日記] [更新:"2015/10/18 23:35:32"]

#1 [pkgsrc] devel/gconfmm

cf-r4-RF@makoto 08:35:07/151019(..devel/libsigc++)% \ less /export/CHROOT/bulklog/gconfmm-2.28.3nb17/build.log
/usr/pkgsrc/devel/gconfmm/work/.buildlink/include/sigc++-2.0/sigc++/functors/slot.h:526:19: 
   note:   no known conversion for argument 1 from 'Glib::Error' to 'int'
client.cc: In function 
   'void {anonymous}::Client_signal_error_callback(GConfClient*, GError*, void*)':
client.cc:401:1: error: no match for call to 
   '(SlotType {aka sigc::slot<void, const Glib::Error&>}) (Glib::Error)' );
  
Makefile:419: recipe for target 'client.lo' failed


2015年10月11日() 旧暦 [n年日記] [更新:"2015/10/12 07:34:42"]

#1 [NetBSD][install] installboot

  1. networkboot
  2. mount /dev/wd0a /mnt
  3. chroot /mnt
  4. mount -a
  5. # installboot -fv /dev/rwd0a bootxx_ffsv1
    File system:         /dev/rwd0a
    Primary bootstrap:   bootxx_ffsv1
    Boot options:        timeout 5, flags 0, speed 9600, ioaddr 0, console pc
    
    # installboot -o console=com0 bootxx_ffsv1
    installboot: Please specify the primary bootstrap file
    # installboot -e  -o console=com0 bootxx_ffsv1
    

#2 [pkgsrc] How to test Canna on Emacs

tsutsui presented canna 3.7 package


And then I've update wip side
  1. (cd /usr/pkgsrc/wip/canna;        make package-install)
    (cd /usr/pkgsrc/wip/canna-canuum; make package-install)
    
  2. (cd /usr/pkgrc/wip/tamago-tsunagi; make package-install)
    
  3. sudo cp  /usr/pkg/share/examples/rc.d/canna /etc/rc.d
    sudo /etc/rc.d/canna onestart
    
  4. Have following line in your ~/.emacs.el (or ~/.emacs)
    (add-to-list 'load-path "/usr/pkg/share/emacs/site-lisp/egg/egg/" )
    (load "canna")
    ;;; set-input-method (RET) japanese-egg-canna
    
  5. M-x set-input-method (RET) japanese-egg-canna
    
  6. C-\

canuum segfaults at reset_shell_mode() of libcurses:

(gdb) run
Starting program: /export/WRKOBJDIR/wip/canna-canuum/work/Canna37p3/canuum/canuum 
convert_getterm: canna.c:1249
convert_getterm: canna.c:1283

Program received signal SIGSEGV, Segmentation fault.
0x00007f7ff7417be0 in __stopwin () from /usr/lib/libcurses.so.7
(gdb) bt
#0  0x00007f7ff7417be0 in __stopwin () from /usr/lib/libcurses.so.7
#1  0x00000000004077e6 in convert_getterm ()
#2  0x00000000004028ff in openTermData ()
#3  0x000000000040818c in main ()
(gdb) quit
A debugging session is active.

        Inferior 1 [process 25113] will be killed.

Quit anyway? (y or n) y
h97@makoto 22:45:11/151011(..wip/canna-canuum)% 
with debug print and disabling reset_shell_mode();
h97@makoto 22:56:02/151011(~)%   \
sudo gdb /export/WRKOBJDIR/wip/canna-canuum/work/Canna37p3/canuum/canuum
Password:
Sorry, try again.
Password:
GNU gdb (GDB) 7.7.1
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64--netbsd".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from 
  /export/WRKOBJDIR/wip/canna-canuum/work/Canna37p3/canuum/canuum...
  (no debugging symbols found)...done.
(gdb) run
Starting program: /export/WRKOBJDIR/wip/canna-canuum/work/Canna37p3/canuum/canuum
convert_getterm: canna.c:1249
convert_getterm: canna.c:1283
convert_getterm: canna.c:1287
convert_getterm: canna.c:1292
exec_cmd (login_utmp): Cannot update utmp/wtmp/lastlog
canuum(かな漢字変換フロントエンドプロセッサ)
h97# test
h97# exit
canuumを終わります。
closeTermData: termio.c:183

Program received signal SIGSEGV, Segmentation fault.
0x00007f7ff7417be0 in __stopwin () from /usr/lib/libcurses.so.7
(gdb) bt
#0  0x00007f7ff7417be0 in __stopwin () from /usr/lib/libcurses.so.7
#1  0x000000000040497d in chld_handler ()
#2  0x00007f7ff68a0ce0 in opendir () from /usr/lib/libc.so.12
#3  0x0000000100000014 in ?? ()
#4  0x0000000000000000 in ?? ()
(gdb)


2015年10月10日() 旧暦 [n年日記] [更新:"2015/10/10 14:31:02"]

#1 [xen] xentools45

NetBSD h97 7.0 NetBSD 7.0 (XEN3_DOM0.201509250726Z) amd64
with xenkernel45 and xentools45
h97@makoto 23:23:51/151010(~)% cat  /usr/pkg/etc/xen/disk-h 
kernel = "/export/NETBSD6/usr/INSTALL/kernel/netbsd-INSTALL_XEN3_DOMU.gz"
#kernel = "/netbsd-XEN3_DOMU"
memory = 2048
name = "disk-h"
vcpus = 4
vif = ['bridge=bridge0']
disk = [ 'phy:/dev/wd0h,0x1,w' ]
#root = "/dev/wd0d"
root = "xbd0"
h97@makoto 23:23:39/151010(~)% sudo xl create /usr/pkg/etc/xen/disk-h  -c
Parsing config from /usr/pkg/etc/xen/disk-h
libxl: error: libxl_create.c:1153:domcreate_launch_dm: unable to add disk devices
libxl: error: libxl_device.c:797:libxl__initiate_device_remove: unable to get my domid
libxl: error: libxl.c:1645:devices_destroy_cb: libxl__devices_destroy failed for 1
libxl: info: libxl.c:1691:devices_destroy_cb: forked pid 868 for destroy of domain 1
h97@makoto 23:30:16/151010(~)% sudo xenstore-ls -fp
/tool = ""   (n0)
/tool/xenstored = ""   (n0)
/vm = ""   (n0)
/vm/fb30fc74-506f-e511-a6f3-d050993b4aa2 = ""   (n0,r13)
/vm/fb30fc74-506f-e511-a6f3-d050993b4aa2/name = "disk-h"   (n0,r13)
/vm/fb30fc74-506f-e511-a6f3-d050993b4aa2/uuid = "fb30fc74-506f-e511-a6f3-d050993b4aa2"   (n0,r13)
/vm/fb30fc74-506f-e511-a6f3-d050993b4aa2/image = ""   (n0,r13)
/vm/fb30fc74-506f-e511-a6f3-d050993b4aa2/image/ostype = "linux"   (n0,r13)
/vm/fb30fc74-506f-e511-a6f3-d050993b4aa2/image/kernel = "/export/NETBSD6/usr/INSTALL/kernel/netbsd-INSTALL_XEN3_DOMU.gz"   (n0,r13)
/vm/fb30fc74-506f-e511-a6f3-d050993b4aa2/start_time = "1444482705.55"   (n0,r13)
/libxl = ""   (n0)
/libxl/13 = ""   (n0)
/local = ""   (n0)
/local/domain = ""   (n0)
/local/domain/0 = ""   (n0)
/local/domain/0/name = "Domain-0"   (n0)
/local/domain/0/memory = ""   (n0)
/local/domain/0/memory/target = "8388608"   (n0)
/local/domain/0/memory/static-max = "4294967292"   (n0)
/local/domain/0/memory/freemem-slack = "2506611"   (n0)
/local/domain/0/libxl = ""   (n0)
/local/domain/0/libxl/disable_udev = "1"   (n0)
/local/domain/0/backend = ""   (n0)
/local/domain/0/backend/vbd = ""   (n0)
/local/domain/0/backend/vbd/1 = ""   (n0)
/local/domain/0/backend/vbd/1/1 = ""   (n0,r1)
/local/domain/0/backend/vbd/1/1/frontend = "/local/domain/1/device/vbd/1"   (n0,r1)
/local/domain/0/backend/vbd/1/1/params = "/dev/wd0h"   (n0,r1)
/local/domain/0/backend/vbd/1/1/script = "/usr/pkg/etc/xen/scripts/block"   (n0,r1)
/local/domain/0/backend/vbd/1/1/physical-device = "0:7"   (n0,r1)
/local/domain/0/backend/vbd/1/1/frontend-id = "1"   (n0,r1)
/local/domain/0/backend/vbd/1/1/online = "1"   (n0,r1)
/local/domain/0/backend/vbd/1/1/removable = "0"   (n0,r1)
/local/domain/0/backend/vbd/1/1/bootable = "1"   (n0,r1)
/local/domain/0/backend/vbd/1/1/state = "6"   (n0,r1)
/local/domain/0/backend/vbd/1/1/dev = "0x1"   (n0,r1)
/local/domain/0/backend/vbd/1/1/type = "phy"   (n0,r1)
/local/domain/0/backend/vbd/1/1/mode = "w"   (n0,r1)
/local/domain/0/backend/vbd/1/1/device-type = "disk"   (n0,r1)
/local/domain/0/backend/vbd/1/1/discard-enable = "1"   (n0,r1)
h97@makoto 23:30:23/151010(~)% 


2015年10月05日(月) 旧暦 [n年日記] [更新:"2015/10/12 07:39:48"]

#1 [xen] 久振りの xen

  • NetBSD/amd64 7.99.20 が入っている機械を xen にしようとした
  • しかし DOM0 kernel を 7.99.20 などから持って来ると panic する
  • そこで 7.0 の DOM0 を使って boot
  • pkgsrc から次の二つを入れておく
    xentools42
    xenkernels42
    
  • /boot.cfg にそれなりの設定をする
    menu=Xen 7.0:load /netbsd-7.0-XEN3_DOM0.gz console=pc;multiboot /xen.gz dom0_mem=8192M
    
  • /etc/brconfig.bridge0 を設定
     h97@makoto 22:42:00/151005(~)% cat /etc/ifconfig.bridge0 
     create
     !brconfig $int add wm0 stp wm0 up
    
  • /usr/pkg/etc/xen/disk-h にそれなりの設定
    kernel = "/export/NETBSD6/usr/INSTALL/kernel/netbsd-INSTALL_XEN3_DOMU.gz"
    #kernel = "/netbsd-XEN3_DOMU"
    memory = 1024
    name = "disk-h"
    #vcpus = 1
    disk = [ 'phy:/dev/wd0h,0x03,w']
    vif = [ 'bridge=bridge0' ]
    #root = "/dev/wd0d"
    root = "xbd0"
    
  • sudo xm create -c disk-h をすると、何だか止ってしまう
    Using config file "/usr/pkg/etc/xen/disk-h".
    Started domain disk-h (id=2)
    Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
        2006, 2007, 2008, 2009, 2010, 2011, 2012
        The NetBSD Foundation, Inc.  All rights reserved.
    Copyright (c) 1982, 1986, 1989, 1991, 1993
        The Regents of the University of California.  All rights reserved.
    
    NetBSD 6.1_STABLE (INSTALL_XEN3_DOMU)
    total memory = 65536 KB
    avail memory = 49876 KB
    mainbus0 (root)
    hypervisor0 at mainbus0: Xen version 4.2.5
    vcpu0 at hypervisor0: Intel(R) Core(TM) i7-4790K CPU @ 4.00GHz, id 0x306c3
    xenbus0 at hypervisor0: Xen Virtual Bus Interface
    xencons0 at hypervisor0: Xen Virtual Console Driver
    xbd0 at xenbus0 id 3: Xen Virtual Block Device Interface
    xbd1 at xenbus0 id 4: Xen Virtual Block Device Interface
    xennet0 at xenbus0 id 0: Xen Virtual Network Interface
    xennet0: MAC address 00:16:3e:5d:37:77
    balloon0 at xenbus0 id 0: Xen Balloon driver
    balloon0: current reservation: 65536 KiB
    xennet0: using RX copy mode
    balloon0: current reservation: 16384 pages => target: 16384 pages
    
  • /var/log/messages を見ると
    xenstored: Checking store ...
    xenstored: Checking store complete.
    /netbsd: balloon0 at xenbus0 id 0: Xen Balloon driver
    /netbsd: balloon0: current reservation: 8388608 KiB
    /netbsd: balloon0: current reservation: 2097152 pages => target: 2097152 pages
    root: /etc/rc: WARNING: $xenwatchdog is not set properly - see rc.conf(5).
    /netbsd: xbdback backend/vbd/1/3: can't VOP_OPEN device 0x7: 6
    xenbackendd[697]: Failed to read /local/domain/0/backend/vbd/1/3/state (No such file or directory)
    xenbackendd[697]: Failed to read /local/domain/0/backend/vbd/1/3/state (No such file or directory)
    /netbsd: xbdback backend/vbd/2/3: can't VOP_OPEN device 0x7: 6
    /netbsd: xvif2i0: Ethernet address 00:16:3e:5e:37:77
    /netbsd: xbd backend: attach device vnd0d (size 6166) for domain 2
    /netbsd: xbd backend domain 2 handle 0x3 (3) using event channel 15, protocol x86_64-abi
    /netbsd: xbd backend domain 2 handle 0x4 (4) using event channel 16, protocol x86_64-abi
    
    Control ] で抜ける。
  • h97@makoto 22:41:06/151005(~)% sudo xm list
    Password:
    Name                                        ID   Mem VCPUs      State   Time(s)
    Domain-0                                     0  8192     1     r-----      6.5
    disk-h                                       2    64     1     -b----      1.1
    
(xentools4*, xenkernel4*) は xm でなく xl を使うようになったような。
という訳で、僕は時代遅れ。要出直。


2015年10月02日(金) 旧暦 [n年日記] [更新:"2015/10/02 22:13:52"]

#1 [pkgsrc] wip/virtualbox-ose

When compiling /usr/ports/emulators/virtualbox-ose with
WRKDIRPREFIX=/WRKDIRPREFIX
MAKE_JOBS=1
in /etc/make.conf:
awk '{print $1, $2, $3}' ~/virtaulbox-ose-make-jobs-1-log | grep 'kBuild: Compiling' | uniq
the log looks like this. or
awk '{print $1, $2, $3}' ~/virtaulbox-ose-make-jobs-1-log | egrep 'kBuild: Compiling|kBuild: Linking' | uniq 
Compiling and Linking
While on pkgsrc h97@makoto 00:57:24/151003(..wip/virtualbox-ose)% awk '{print $1, $2, $3}' /export/log | egrep 'kBuild: Compiling|kBuild: Linking' | uniq
kBuild: Compiling bin2c
kBuild: Linking bin2c
kBuild: Compiling biossums
kBuild: Linking biossums
kBuild: Compiling filesplitter
kBuild: Linking filesplitter
kBuild: Compiling VBoxCmp
kBuild: Linking VBoxCmp
kBuild: Compiling RuntimeBldProg
kBuild: Compiling bin2c
kBuild: Compiling biossums
kBuild: Compiling filesplitter
kBuild: Compiling VBoxCmp
kBuild: Compiling RuntimeBldProg
kBuild: Compiling scm
kBuild: Compiling VBoxCPP
kBuild: Compiling VBoxTpG
kBuild: Compiling VBoxDef2LazyLoad
NetBSD has following at Compiling RuntimeBldProg
/export/WRKOBJDIR/wip/virtualbox-ose/work/VirtualBox-4.3.30/ ->
src/VBox/Runtime/r3/freebsd/rtProcInitExePath-freebsd.cpp:84:51:
error: too few arguments to function 
'int rtPathFromNative(const char**, const char*, const char*)'
         int rc = rtPathFromNative(&pszTmp, pszPath);
                                                   ^
In file included from
/export/WRKOBJDIR/wip/virtualbox-ose/work/VirtualBox-4.3.30/ ->
src/VBox/Runtime/r3/freebsd/rtProcInitExePath-freebsd.cpp:43:0:
/export/WRKOBJDIR/wip/virtualbox-ose/work/VirtualBox-4.3.30/ ->
src/VBox/Runtime/include/internal/path.h:95:5:
note: declared here
 int rtPathFromNative(const char **ppszPath, const char *pszNativePath, 
     ^
const char *pszBasePath);

/export/WRKOBJDIR/wip/virtualbox-ose/work/VirtualBox-4.3.30/ ->
src/VBox/Runtime/r3/freebsd/rtProcInitExePath-freebsd.cpp:89:34:
error: too few arguments to function 
'void rtPathFreeIprt(const char*, const char*)'
             rtPathFreeIprt(pszTmp);



最近の日記
2024年05月08日
comparison on ./buildsh tools
2024年05月06日
py-setuptools (python 3.11.9)
make release took 1 hours and 10 min
qemu invocation for 10.99.10
2024年05月05日
Windows 10 version
serial connection
bc bench
2024年05月04日
Trial on 10.99.10
another version (later trial) to succeed
2024年04月29日
dkim
以上、6 日分です。
タイトル一覧
カテゴリ分類
Powered by hns-2.19.9, HyperNikkiSystem Project

Count.cgi (since 2000/02/05)