From mboxrd@z Thu Jan 1 00:00:00 1970 From: taylanbayirli@gmail.com (Taylan Ulrich =?UTF-8?Q?Bay=C4=B1rl=C4=B1/Kammer?=) Subject: bug#22354: Test failure when running distcheck from out-of-tree build Date: Wed, 13 Jan 2016 11:42:16 +0100 Message-ID: <87egdlvjzr.fsf@T420.taylan> References: <87r3hnuple.fsf@T420.taylan> <87ziwan3kx.fsf@gnu.org> <87mvsavb61.fsf@T420.taylan> <87k2nea582.fsf@gnu.org> <87io2xvooo.fsf@T420.taylan> <871t9l949a.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:52838) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aJItO-0008C4-0q for bug-guix@gnu.org; Wed, 13 Jan 2016 05:43:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aJItK-0002nP-Ob for bug-guix@gnu.org; Wed, 13 Jan 2016 05:43:05 -0500 Received: from debbugs.gnu.org ([208.118.235.43]:59626) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aJItK-0002nJ-Ku for bug-guix@gnu.org; Wed, 13 Jan 2016 05:43:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84) (envelope-from ) id 1aJItK-00088Q-GP for bug-guix@gnu.org; Wed, 13 Jan 2016 05:43:02 -0500 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <871t9l949a.fsf@gnu.org> ("Ludovic \=\?utf-8\?Q\?Court\=C3\=A8s\=22'\?\= \=\?utf-8\?Q\?s\?\= message of "Wed, 13 Jan 2016 11:13:05 +0100") List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 22354-done@debbugs.gnu.org ludo@gnu.org (Ludovic Court=C3=A8s) writes: > taylanbayirli@gmail.com (Taylan Ulrich "Bay=C4=B1rl=C4=B1/Kammer") skribi= s: > >> Yes, it still goes through the tests and fails at guix-environment.sh >> with the same error. I repeated all steps from a new clone of master. >> >> taylan@T420:~/src/guix/build$ grep length guix-0.9.1/_build/sub/config.l= og >> configure:6946: checking the length of the installed socket file name >> configure:6969: checking the length of the socket file name used in tests >> configure:6980: checking the length of a typical hash bang line >> configure:6992: checking the length of a hash bang line used in tests >> ac_cv_guix_hash_bang_length=3D73 >> ac_cv_guix_socket_file_name_length=3D74 >> ac_cv_guix_test_hash_bang_length=3D127 >> ac_cv_guix_test_socket_file_name_length=3D90 > > Arff, I see. I=E2=80=99ve change LINUX_HASH_BANG_LIMIT in guix.m4 to 127 > instead of 128 to account for the trailing zero. > > This time it should detect the problem early. Indeed, it fails with a meaningful error message at the beginning of the check phase now. > The =E2=80=9Cbad interpreter=E2=80=9D message comes from Bash, in execute= _cmd.c. > > However, that file does this: > > char sample[80]; > > [=E2=80=A6] > > #if defined (HAVE_HASH_BANG_EXEC) > READ_SAMPLE_BUF (command, sample, sample_len); > sample[sample_len - 1] =3D '\0'; > if (sample_len > 2 && sample[0] =3D=3D '#' && sample[1] =3D=3D '!') > { > char *interp; > int ilen; > > interp =3D getinterp (sample, sample_len, (int *)NULL); > > where READ_SAMPLE_BUF is: > > #define READ_SAMPLE_BUF(file, buf, len) \ > do \ > { \ > fd =3D open(file, O_RDONLY); \ > if (fd >=3D 0) \ > { \ > len =3D read (fd, buf, 80); \ > close (fd); \ > } \ > else \ > len =3D -1; \ > } \ > while (0) > > Now we know. :-) Yay for hard-coded limits! :P > Ludo=E2=80=99. Taylan