From owner-freebsd-questions@FreeBSD.ORG Wed May 18 10:34:24 2005 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9800E16A4CE for ; Wed, 18 May 2005 10:34:24 +0000 (GMT) Received: from mx2.fujixerox.co.jp (mx2.fujixerox.co.jp [192.26.96.12]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5707343D69 for ; Wed, 18 May 2005 10:34:23 +0000 (GMT) (envelope-from Qiang.Xu@fujixerox.com) Received: from isvw2.fujixerox.co.jp ([129.249.27.132]) by mx2.fujixerox.co.jp (8.11.6p2a/3.7W) with ESMTP id j4IAYGm10972; Wed, 18 May 2005 19:34:16 +0900 (JST) Received: from ms1.fujixerox.co.jp (isvw2 [129.249.27.132]) by isvw2.fujixerox.co.jp (8.11.6p2a/3.7W) with ESMTP id j4IAY8s19878; Wed, 18 May 2005 19:34:08 +0900 (JST) Received: from sgpaphq-smtp01.fujixerox.com ([13.198.8.73]) by ms1.fujixerox.co.jp (8.11.6p2a/3.7W) with ESMTP id j4IAYEa13123; Wed, 18 May 2005 19:34:14 +0900 (JST) Received: from 10.198.8.10 by sgpaphq-smtp01.fujixerox.com with ESMTP id 50546701116412125; Wed, 18 May 2005 18:28:45 +0800 Received: from localhost (localhost [127.0.0.1]) by localhost.sgp.fujixerox.com (Postfix) with SMTP id 4359D1D936; Wed, 18 May 2005 18:22:05 +0800 (SGT) Received: from sess.xssc.sgp.xerox.com (unknown [13.198.33.122]) by imss.sgp.fujixerox.com (Postfix) with ESMTP id 0C1811D936; Wed, 18 May 2005 18:21:39 +0800 (SGT) From: Xu Qiang To: Ted Mittelstaedt , Dan Nelson , Giorgos Keramidas Date: Wed, 18 May 2005 18:31:07 +0800 X-Sent-Folder-Path: Sent Items X-Mailer: Oracle Connector for Outlook 9.0.4 60130 (9.0.2711) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary=-------4c4559824c455982 Message-Id: <20050518102139.0C1811D936@imss.sgp.fujixerox.com> cc: "Qiang \(XSSC\) Xu" cc: freebsd-questions@freebsd.org Subject: RE: The availability of socketbits.h? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 May 2005 10:34:24 -0000 This is a multi-part message in MIME format ---------4c4559824c455982 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Ted Mittelstaedt wrote: > Would you post a diff of the files you had to change to the list once > you get it running? With the help of Giorgos, I finally got all the diff into separate patch fi= les. = Explanatory notes: = 1. I am using mlrate-1.1.0.tar.gz and nngs-1.1.14.tar.gz (coz it is more st= able and reliable than 1.1.16 version), and only nngs-1.1.14.tar.gz need to= be patched. = 2. configure.patch must be applied in order to compile nngs src in FreeBSD = 5.3 (for i386) with gcc 3.4.2; the patch is hinted by this bug reported in = sourceforge: = http://sourceforge.net/tracker/index.php?func=3Ddetail&aid=3D1201565&group_= id=3D59572&atid=3D491424 For your convenience, the gist is listed here: = ----------------------------------------------- -lang-c89 deprecated = quote from man gcc (3.3.5-20050130) Note: Previous versions of cpp accepted a -lang option which selected both the language and the standards conformance level. This option has been removed, because it conflicts with the -l option. just use -std=3Dc89 (not sure but seem to works) ----------------------------------------------- P.S.: Although this can work, I can't find the option "-std" in "man gcc", = quite strange. Any hints? 3. Up to now, the compilation can be done successfully with GNU make, but i= f the following patch(es) is/are not applied, the compiled binary (nngssrv)= will throw a run-time error and dump core. The patches are credited to Dan= Nelson and Giorgos Keramidas. Either one set of the patches is enough to a= void the run-time error. Which one to choose is up to your own. i) The patch of Dan Nelson involves only one file - command.c, and the patc= h file is command.c.patch.DanNelson ii) The patch of Giorgos involves two files - command.c and command_list.h,= the patch files are command.c.patch.GiorgosKeramidas and command_list.h.pa= tch.GiorgosKeramidas If you meet any other problem in the process of setting up the server, pls = let us know. P.S.: After using Giorgos' method to create the diff patches, I don't know = how to apply the patches back to the original file(s). Can Giorgos help me = once more? (Actually, I am quite a newbie in FreeBSD world.) 4. Final word: when configure nngs src, it is best to enable adminlevels op= tions, it is done by: ./configure --prefix=3D --enable-adminlevels Hope this open-source software can be integrated into "ports" system of Fre= eBSD. Thank you, all. Regards, Xu Qiang ---------4c4559824c455982 Content-Type: application/octet-stream; name="command.c.patch.DanNelson" Content-Disposition: attachment; filename="command.c.patch.DanNelson" Content-Transfer-Encoding: base64 LS0tIGNvbW1hbmQuYy5vcmcJV2VkIE1heSAxOCAxODowNDoxMCAyMDA1CisrKyBjb21tYW5k LmMJV2VkIE1heSAxOCAxODoxMTo0MSAyMDA1CkBAIC0xMTQyLDcgKzExNDIsNyBAQAogICAg IGZjbG9zZShmcCk7CiAgICAgcmV0dXJuOwogICB9Ci0gIGZvcihpPTA7IGNvbW1hbmRfbGlz dFtpXS5jb21tX25hbWU7IGkrKykgeworICBmb3IoaT0wOyBpPG5vb2Zjb21tczsgaSsrKSB7 CiAgICAgaWYgKGNvbW1hbmRfbGlzdFtpXS5hZG1pbkxldmVsID49IEFETUlOX0FETUlOKSB7 CiAgICAgICBmcHJpbnRmKGFmcCwgIiVzXG4iLCBjb21tYW5kX2xpc3RbaV0uY29tbV9uYW1l KTsKICAgICB9IGVsc2Ugewo= ---------4c4559824c455982 Content-Type: application/octet-stream; name="command.c.patch.GiorgosKeramidas" Content-Disposition: attachment; filename="command.c.patch.GiorgosKeramidas" Content-Transfer-Encoding: base64 LS0tIGNvbW1hbmQuYy5vcmcJV2VkIE1heSAxOCAxODowNDoxMCAyMDA1CisrKyBjb21tYW5k LmMJV2VkIE1heSAxOCAxODoxNTo0NCAyMDA1CkBAIC0yMDgsNyArMjA4LDcgQEAKIHsKICAg aWYgKCFub29mY29tbXMpCiAgIHsKLSAgICBub29mY29tbXMgPSBDT1VOVE9GKGNvbW1hbmRf bGlzdCk7CisgICAgbm9vZmNvbW1zID0gQ09VTlRPRihjb21tYW5kX2xpc3QpIC0gMTsKICAg ICBxc29ydCgmKGNvbW1hbmRfbGlzdCksbm9vZmNvbW1zLHNpemVvZiBjb21tYW5kX2xpc3Rb MF0sJmNvbW1hbmRfY21wKTsKICAgfQogfQo= ---------4c4559824c455982 Content-Type: application/octet-stream; name="command_list.h.patch.GiorgosKeramidas" Content-Disposition: attachment; filename="command_list.h.patch.GiorgosKeramidas" Content-Transfer-Encoding: base64 LS0tIGNvbW1hbmRfbGlzdC5oLm9yZwlXZWQgTWF5IDE4IDE4OjA0OjIyIDIwMDUKKysrIGNv bW1hbmRfbGlzdC5oCVdlZCBNYXkgMTggMTg6MTY6MjggMjAwNQpAQCAtMjQyLDYgKzI0Miw3 IEBACiAjZW5kaWYKICAgLyogYnkgU3luY2FucGggKi8KICAgeyJzaG93bm90ZSIsICAgICAg ICAgICIiLCAgICAgY29tX3Nob3dub3RlLCAgIEFETUlOX1VTRVIgfSwKKyAgezAsCQkJMCwJ MCwJCTAgfQogfTsKIAogc3RydWN0IGFsaWFzX3R5cGUgZ19hbGlhc19saXN0W10gPSB7Cg== ---------4c4559824c455982 Content-Type: application/octet-stream; name="configure.patch" Content-Disposition: attachment; filename="configure.patch" Content-Transfer-Encoding: base64 LS0tIGNvbmZpZ3VyZS5vcmcJV2VkIE1heSAxOCAxNDowMDozMSAyMDA1CisrKyBjb25maWd1 cmUJV2VkIE1heSAxOCAxNDowMTozMSAyMDA1CkBAIC01MjMxLDggKzUyMzEsOCBAQAogTk9f V0FSTklOR1M9IkNGTEFHUz0kQ0ZMQUdTIgogaWYgdGVzdCAkYWNfY3ZfY19jb21waWxlcl9n bnUgPSB5ZXM7IHRoZW4KICAgR0NDX09OTFk9JycKLSAgR0dPX1NPTUVfV0FSTklOR1M9Jy1X YWxsIC1XIC1XcG9pbnRlci1hcml0aCAtV2JhZC1mdW5jdGlvbi1jYXN0IC1XY2FzdC1xdWFs IC1XY2FzdC1hbGlnbiAtV3dyaXRlLXN0cmluZ3MgLVdzdHJpY3Q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