I've been trying to build Samba 3.0.4 on QNX 6.1.0. 1. I downloaded the source tarball "samba-latest.tar.gz" from a mirror site. The downloading was done on an MS-Windows system. The tarball was transferred to the QNX box by loading into Emacs on MS-Windows with "M-x find-file-literally" then saving it with Emacs's ftp facility: "C-x C-w /root@ww.xx.yy.zz:/<directory>" [where ww.xx.yy.zz. is the IP address of the QNX machine]. 2. I logged on as root in the QNX machine. 3. I unpacked it into a sensible directory with "gunzip" and "tar -xf samba-latest.tar". [tar reported that two files couldn't be unpacked because their names were too long: ../docs/htmldocs/guide/.....ProtocolStats.png and TraceStats.png, but this is probably (hopefully?) unimportant.] 4. From ...../samba-3.0.4/source I did # ./configure | tee configure-messages.txt and this seemed to work OK. 5. # make 2> make-stderr.txt | tee make-stdout.txt This produced this error message: gawk: script/mkproto.awk:14: fatal: cannot open file `cnrpc_client/cli_lsarpc.cnrpc_client/cli_samr.cnrpc_client/cli_netlogon.cnrpc_client/... [middle of very long error message line snipped] ..../srv_spoolss_nt.cnrpc_server/srv_echo.cnrpc_server/srv_echo_nt.cnsam/idmap.cnsam/idmap_util.cnsam/idmap_tdb.cnlibsmb/spnego.cnlibsmb/passchange.c' for reading (Filename too long) The entire output on stdout was: Using FLAGS = -O -I./popt -Iinclude -I/home/AM/samba-3.0.4/source/include -I/home/AM/samba-3.0.4/source/ubiqx -I/home/AM/samba-3.0.4/source/smbwrapper -I. -I/home/AM/samba-3.0.4/source LIBS = -lsocket LDSHFLAGS = -shared LDFLAGS = Generating smbd/build_options.c Building include/proto.h creating /home/AM/samba-3.0.4/source/include/proto.h Building include/wrepld_proto.h creating /home/AM/samba-3.0.4/source/include/wrepld_proto.h Building include/build_env.h creating /home/AM/samba-3.0.4/source/nsswitch/winbindd_proto.h creating /home/AM/samba-3.0.4/source/web/swat_proto.h creating /home/AM/samba-3.0.4/source/client/client_proto.h creating /home/AM/samba-3.0.4/source/utils/net_proto.h creating /home/AM/samba-3.0.4/source/utils/ntlm_auth_proto.h Compiling dynconfig.c 5. Curiously, "make -n > make-n.txt" [make -n means "run make reporting actions to be done without actually doing them.] (produces a decent looking output, starting thus: echo "Using FLAGS = -O -I./popt -Iinclude -I/home/AM/samba-3.0.4/source/include -I/home/AM/samba-3.0.4/source/ubiqx -I/home/AM/samba-3.0.4/source/smbwrapper -I. -I/home/AM/samba-3.0.4/source " echo " LIBS = -lsocket" echo " LDSHFLAGS = -shared " echo " LDFLAGS = " echo Compiling dynconfig.c gcc -O -I./popt -Iinclude -I/home/AM/samba-3.0.4/source/include -I/home/AM/samba-3.0.4/source/ubiqx -I/home/AM/samba-3.0.4/source/smbwrapper -I. -I/home/AM/samba-3.0.4/source -DCONFIGFILE=\"/usr/local/samba/lib/smb.conf\" -DSBINDIR=\"/usr/local/samba/sbin\" -DBINDIR=\"/usr/local/samba/bin\" -DDRIVERFILE=\"\" -DLMHOSTSFILE=\"/usr/local/samba/lib/lmhosts\" -DSWATDIR=\"/usr/local/samba/swat\" -DLOCKDIR=\"/usr/local/samba/var/locks\" -DPIDDIR=\"/usr/local/samba/var/locks\" -DLIBDIR=\"/usr/local/samba/lib\" -DLOGFILEBASE=\"/usr/local/samba/var\" -DSHLIBEXT=\"so\" -DCONFIGDIR=\"/usr/local/samba/lib\" -DSMB_PASSWD_FILE=\"/usr/local/samba/private/smbpasswd\" -DPRIVATE_DIR=\"/usr/local/samba/private\" -c dynconfig.c -o dynconfig.o if (: >> param/loadparm.o || : > param/loadparm.o) >/dev/null 2>&1; then rm -f param/loadparm.o; else \ dir=`echo param/loadparm.o | sed 's,/[^/]*$,,;s,^$,.,'` || exec false; if test -d "$dir"; then :; else echo mkdir "$dir"; mkdir -p "$dir" >/dev/null 2>&1 || test -d "$dir" || mkdir "$dir" || exec false; fi || exec false; fi echo Compiling param/loadparm.c I'd greatly appreciate help getting the build scripts working on my system. Thanks in advance! -- Alan Mackenzie Motorola, Munich (Germany)
On Sat, 2004-07-17 at 01:01, Mackenzie Alan-G25604 wrote:> I've been trying to build Samba 3.0.4 on QNX 6.1.0. > > 1. I downloaded the source tarball "samba-latest.tar.gz" from a mirror > site. The downloading was done on an MS-Windows system. The tarball was > transferred to the QNX box by loading into Emacs on MS-Windows with "M-x > find-file-literally" then saving it with Emacs's ftp facility: "C-x C-w > /root@ww.xx.yy.zz:/<directory>" [where ww.xx.yy.zz. is the IP address of > the QNX machine]. > > 2. I logged on as root in the QNX machine. > > 3. I unpacked it into a sensible directory with "gunzip" and "tar -xf > samba-latest.tar". [tar reported that two files couldn't be unpacked > because their names were too long: > ../docs/htmldocs/guide/.....ProtocolStats.png and TraceStats.png, but > this is probably (hopefully?) unimportant.] > > 4. From ...../samba-3.0.4/source I did > # ./configure | tee configure-messages.txt > and this seemed to work OK. > > 5. # make 2> make-stderr.txt | tee make-stdout.txt > This produced this error message: > gawk: script/mkproto.awk:14: fatal: cannot open file > `cnrpc_client/cli_lsarpc.cnrpc_client/cli_samr.cnrpc_client/cli_netlogon.cnrpc_client/... > [middle of very long error message line snipped] > ..../srv_spoolss_nt.cnrpc_server/srv_echo.cnrpc_server/srv_echo_nt.cnsam/idmap.cnsam/idmap_util.cnsam/idmap_tdb.cnlibsmb/spnego.cnlibsmb/passchange.c' for reading (Filename too long)Sounds like something isn't quite standard with QNX (causing the concatenation). You could, as a workaround, run 'make proto' on a linux box, and ship the proto.h across. If you figure out why it's happening, then please file a bug (with patch if possible) Andrew Bartlett -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part Url : http://lists.samba.org/archive/samba/attachments/20040717/3b181085/attachment.bin
-----Original Message----- From: Andrew Bartlett [mailto:abartlet@samba.org] Sent: 17 July 2004 00:41 To: Mackenzie Alan-G25604 Cc: samba@lists.samba.org Subject: Re: [Samba] Can't build 3.0.4 under QNX 6.1.0>On Sat, 2004-07-17 at 01:01, Mackenzie Alan-G25604 wrote: >> I've been trying to build Samba 3.0.4 on QNX 6.1.0.[ .... ]>> 5. # make 2> make-stderr.txt | tee make-stdout.txt >> This produced this error message: >> gawk: script/mkproto.awk:14: fatal: cannot open file >> `cnrpc_client/cli_lsarpc.cnrpc_client/cli_samr.cnrpc_client/cli_netlogon.cnrpc_client/... >> [middle of very long error message line snipped] >>..../srv_spoolss_nt.cnrpc_server/srv_echo.cnrpc_server/srv_echo_nt.cnsam/idmap.cnsam/idmap_util.cnsam/idmap_tdb.cnlibsmb/spnego.cnlibsmb/passchange.c' for reading (Filename too long)> Sounds like something isn't quite standard with QNX (causing the > concatenation). You could, as a workaround, run 'make proto' on a linux > box, and ship the proto.h across.> If you figure out why it's happening, then please file a bug (with patch > if possible)The problem is in ..../source/script/mkproto.sh within the line: proto_src="`echo $@ | tr ' ' '\n' | sed -e 's/\.o/\.c/g' | sort | uniq | egrep -v 'ubiqx/|wrapped|modules/getdate'`" ^^^^^^^^^^^ In the tr call, QNX's shell is substituting space with literal 'n' rather than carriage returns. So, rather than being divided up into single lines with one file.c on each line, they're all crammed together onto a single line, separated uselessly by 'n's. :-(. I'm not a shell expert, but NOTHING I tried could persuade QNX's shell to interpret '\n' as carriage return. Trying a sed in place of the tr didn't help either. As a workaround, I put in an AWK script instead. (OK, this is overkill, but it seemed to work.) In fact, I took out the sed command too, so it didn't look _too_ abtuse. Here is what "seemed to work" for me: proto_src="`echo $@ | gawk '{for (i = 1 ; i <= NF ; i += 1) {gsub (/\.o/, ".c", $i); print $i}}' | sort | uniq | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ rep -v 'ubiqx/|wrapped|modules/getdate'`" (Apologies for any line-break problems in the above. I'm using MS Outlook. :-() When I say "seemed to work", I mean that the build hung up later on on something else. :-( I'll get there! Andrew Bartlett -- Alan Mackenzie (Motorola, Munich)