From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from nm36-vm6.bullet.mail.bf1.yahoo.com (nm36-vm6.bullet.mail.bf1.yahoo.com [72.30.238.142]) by fantadrom.bsd.lv (OpenSMTPD) with ESMTP id 467975aa for ; Fri, 6 Nov 2015 23:21:03 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com.au; s=s2048; t=1446870062; bh=llXUrJV4dMumGnrlzsAjhigdZRkwTccUXbaHPvt09rU=; h=Date:From:To:Subject:From:Subject; b=Auc6YgBHtQHHWMBlrttVYRdw4t0k5frQOMmnTIrXfPytTjlZNRl/WaIkXgNTa8/LKbWkt0vnzuXUdhcc93bDANRUmsBPiz63rc8G/2f7WZVbhIZDZnkcvQeb83JSFO4PF3hXv0cJb6h5Px/rR6lndxuNrLIAQb/qiSRbOFrdnx8r7Z3Z3gtZSGx+aP7NojiPy7RSGLQcHuv3+qzqBln6I5WT3iPSrXSEWJc+iKBtQ4UeZq4Yqi89IHs6kFuLsn/G9RBQ8F1B8Nb4L/xOj6Gl7jD0a6IXrzxhbT8wzpIuYxjQbyBq6769pWh/0Dl7REPq4/tqrycHmSni598gwX3r9A== Received: from [66.196.81.173] by nm36.bullet.mail.bf1.yahoo.com with NNFMP; 07 Nov 2015 04:21:02 -0000 Received: from [98.139.211.196] by tm19.bullet.mail.bf1.yahoo.com with NNFMP; 07 Nov 2015 04:21:02 -0000 Received: from [127.0.0.1] by smtp205.mail.bf1.yahoo.com with NNFMP; 07 Nov 2015 04:21:02 -0000 X-Yahoo-Newman-Id: 762745.30809.bm@smtp205.mail.bf1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: SRRzGAIVM1kOtSEbBLiz6PFS4AJ5IURQYGEWwdJ_thlGm4A YUl3p0njZ2X3XoQ9qyhct_7.chDvbSJKrzjOB63777w9U0DPBDDPUT9_Yvbi cEYi.yZFe3ciTk_teGDhLJ2CTNVoTz_yRV9FERqIIDgRLMg_hiuAziL2ToQV OyXN8xUUxhSIGJkXyDJrdyF1o1y8KREu36ne4tnh.xOAkzvtl_hbBHWFskEV AcyONurNhVhw3q14bPYVsMPTymMsdhtUlMks7q34LVxzB.pHOOn_jNSONuSN gjJSuRg5bA5i3PZ_unRUb6L7MUP7fZMTXhRGNx.3SHuFBkUpzl7z2_eGV49g IOCHraTHasf_Q2rLxGBRPzfjFZQ064NgKsp9kO4ANl.1pnjAAXoSlLlIDEoX SHHyokeyvJWfF3CEGhHDTxRndAbiDhhgj7eqJFrF4ubCRE_fbqe9E7c1WZgE IsVUGz4NXz7vhRzl2bj5o.OL3w2NkcZ7fes34WavUMg42AgT7muMLxUmiM6I d5T0fVMlDLD3fFG2T1kwtvPBTp9QQgJc- X-Yahoo-SMTP: wy_7AdSswBBaijFlmVnVzTL.0g-- Message-ID: <563D7C2C.1080903@yahoo.com.au> Date: Sat, 07 Nov 2015 15:21:00 +1100 From: Peter Bray User-Agent: Mozilla/5.0 (X11; SunOS i86pc; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 X-Mailinglist: mdocml-discuss Reply-To: discuss@mdocml.bsd.lv MIME-Version: 1.0 To: discuss@mdocml.bsd.lv Subject: mdocml [CVS_2015_11_07] Linking of soelim(1) fails on Solaris 10 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Greetings, soelim(1) fails to link on Solaris 10 systems as the appropriate compatibility code has not been included in the linking of the executable. Changing the Makefile linking command to include additional compatibility object code, as follows: (helps but...) --- Makefile.orig 2015-11-07 00:47:44.000000000 +0000 +++ Makefile 2015-11-07 03:39:21.786602977 +0000 @@ -414,5 +414,5 @@ soelim: $(SOELIM_OBJS) compat_reallocarray.o compat_err.o compat_progname.o - $(CC) $(LDFLAGS) -o $@ $(SOELIM_OBJS) compat_reallocarray.o + $(CC) $(LDFLAGS) -o $@ $(SOELIM_OBJS) compat_reallocarray.o compat_err.o compat_progname.o But, the Solaris 10 build then fails to find getline(3C). Looking at the code base, getline(3C) is only used once: soelim.c:100: while ((linelen = getline(&line, &linecap, f)) > 0) { While a compatibility function fgetln() from compat_fgetln.c is used in many places: manpage.c:127: if (NULL != (cp = fgetln(stdin, &len))) cgi.c:720: while (NULL != (p = fgetln(f, &len))) { cgi.c:1145: while (NULL != (dp = fgetln(fp, &dpsz))) { main.c:791: while ((line = fgetln(stream, &len)) != NULL) { main.c:821: syscall = "fgetln"; mandocdb.c:1309: while (NULL != (line = fgetln(stream, &len))) mandocdb.c:1318: while (NULL != (line = fgetln(stream, &len))) mandocdb.c:1332: while (NULL != (line = fgetln(stream, &len))) { manpath.c:221: while ((cp = fgetln(stream, &len)) != NULL) { Both functions on the surface (and no, I didn't do any investigation), seem to be doing a simalar task (reading a line from a file handle). Question: Should soelim.c also be using fgetln()? Back to the Makefile, I noticed that the unedited file contains: Makefile:267:SOELIM_OBJS = soelim.o compat_stringlist.o Makefile:415:soelim: $(SOELIM_OBJS) compat_reallocarray.o Makefile:416: $(CC) $(LDFLAGS) -o $@ $(SOELIM_OBJS) compat_reallocarray.o Question: Should compat_reallocarray.o and the compatibility object code change I proposed be moved to the definition of SOELIM_OBJS? Regards, Peter Bray Sydney, Australia -- To unsubscribe send an email to discuss+unsubscribe@mdocml.bsd.lv