From 7b0dc2d0b39e56c1d1084dc47915349b34d50f58 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sat, 3 Mar 2007 04:01:15 +0000 Subject: [PATCH] Avoid a link error due to program_name. --- ChangeLog | 4 ++++ modules/carray-list-tests | 1 + modules/linkedhash-list-tests | 1 + tests/test-carray_list.c | 8 ++++++-- tests/test-linkedhash_list.c | 8 ++++++-- 5 files changed, 18 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 331b8226c..91a232017 100644 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,10 @@ 2007-03-02 Bruno Haible + * modules/linkedhash-list-tests (Depends-on): Add progname. + * tests/test-linkedhash_list.c: Include progname.h. + (main): Call set_program_name. + * modules/carray-list-tests (Depends-on): Add progname. * tests/test-carray_list.c: Include progname.h. (main): Call set_program_name. diff --git a/modules/carray-list-tests b/modules/carray-list-tests index a4e373833..82e7b7894 100644 --- a/modules/carray-list-tests +++ b/modules/carray-list-tests @@ -3,6 +3,7 @@ tests/test-carray_list.c Depends-on: array-list +progname configure.ac: diff --git a/modules/linkedhash-list-tests b/modules/linkedhash-list-tests index ea3a47827..296a58784 100644 --- a/modules/linkedhash-list-tests +++ b/modules/linkedhash-list-tests @@ -3,6 +3,7 @@ tests/test-linkedhash_list.c Depends-on: array-list +progname configure.ac: diff --git a/tests/test-carray_list.c b/tests/test-carray_list.c index ac1da7af1..6026cd063 100644 --- a/tests/test-carray_list.c +++ b/tests/test-carray_list.c @@ -1,5 +1,5 @@ /* Test of sequential list data type implementation. - Copyright (C) 2006 Free Software Foundation, Inc. + Copyright (C) 2006-2007 Free Software Foundation, Inc. Written by Bruno Haible , 2006. This program is free software; you can redistribute it and/or modify @@ -20,10 +20,12 @@ # include #endif +#include "gl_carray_list.h" + #include #include "gl_array_list.h" -#include "gl_carray_list.h" +#include "progname.h" static const char *objects[15] = { @@ -60,6 +62,8 @@ main (int argc, char *argv[]) { gl_list_t list1, list2, list3; + set_program_name (argv[0]); + /* Allow the user to provide a non-default random seed on the command line. */ if (argc > 1) srand (atoi (argv[1])); diff --git a/tests/test-linkedhash_list.c b/tests/test-linkedhash_list.c index bcbc9bddf..f368b58df 100644 --- a/tests/test-linkedhash_list.c +++ b/tests/test-linkedhash_list.c @@ -1,5 +1,5 @@ /* Test of sequential list data type implementation. - Copyright (C) 2006 Free Software Foundation, Inc. + Copyright (C) 2006-2007 Free Software Foundation, Inc. Written by Bruno Haible , 2006. This program is free software; you can redistribute it and/or modify @@ -20,12 +20,14 @@ # include #endif +#include "gl_linkedhash_list.h" + #include #include #include #include "gl_array_list.h" -#include "gl_linkedhash_list.h" +#include "progname.h" static const char *objects[15] = { @@ -87,6 +89,8 @@ main (int argc, char *argv[]) { gl_list_t list1, list2, list3; + set_program_name (argv[0]); + /* Allow the user to provide a non-default random seed on the command line. */ if (argc > 1) srand (atoi (argv[1])); -- 2.11.0