]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
Avoid double-including config.h
authorUlf Hermann <ulf.hermann@qt.io>
Thu, 20 Apr 2017 14:31:02 +0000 (16:31 +0200)
committerMark Wielaard <mark@klomp.org>
Tue, 2 May 2017 11:28:54 +0000 (13:28 +0200)
config.h doesn't have include guards, so including it twice is bad. We
deal with this by checking for PACKAGE_NAME, but only in some places.
Once we start using gnulib, we will need to include config.h before any
gnulib-generated headers. This is problematic if we include it
transitively through our own private headers.

In order to set a clear rule about inclusion of config.h, it is now
included in every .c file as first header, but not in any header. This
will definitely avoid double-inclusion and satisfy the condition that it
has to be included before gnulib headers. It comes at the price of
adding some redundancy, but there is no clean way to avoid this.

Signed-off-by: Ulf Hermann <ulf.hermann@qt.io>
62 files changed:
lib/ChangeLog
lib/crc32.c
lib/system.h
libdwfl/ChangeLog
libdwfl/argp-std.c
libdwfl/cu.c
libdwfl/derelocate.c
libdwfl/dwfl_addrdie.c
libdwfl/dwfl_addrdwarf.c
libdwfl/dwfl_addrmodule.c
libdwfl/dwfl_begin.c
libdwfl/dwfl_build_id_find_debuginfo.c
libdwfl/dwfl_build_id_find_elf.c
libdwfl/dwfl_cumodule.c
libdwfl/dwfl_dwarf_line.c
libdwfl/dwfl_end.c
libdwfl/dwfl_frame.c
libdwfl/dwfl_frame_regs.c
libdwfl/dwfl_getdwarf.c
libdwfl/dwfl_getmodules.c
libdwfl/dwfl_getsrc.c
libdwfl/dwfl_getsrclines.c
libdwfl/dwfl_line_comp_dir.c
libdwfl/dwfl_linecu.c
libdwfl/dwfl_lineinfo.c
libdwfl/dwfl_linemodule.c
libdwfl/dwfl_module.c
libdwfl/dwfl_module_addrdie.c
libdwfl/dwfl_module_addrname.c
libdwfl/dwfl_module_addrsym.c
libdwfl/dwfl_module_build_id.c
libdwfl/dwfl_module_dwarf_cfi.c
libdwfl/dwfl_module_eh_cfi.c
libdwfl/dwfl_module_getdwarf.c
libdwfl/dwfl_module_getelf.c
libdwfl/dwfl_module_getsrc.c
libdwfl/dwfl_module_getsrc_file.c
libdwfl/dwfl_module_getsym.c
libdwfl/dwfl_module_info.c
libdwfl/dwfl_module_nextcu.c
libdwfl/dwfl_module_register_names.c
libdwfl/dwfl_module_report_build_id.c
libdwfl/dwfl_module_return_value_location.c
libdwfl/dwfl_nextcu.c
libdwfl/dwfl_onesrcline.c
libdwfl/dwfl_report_elf.c
libdwfl/dwfl_validate_address.c
libdwfl/dwfl_version.c
libdwfl/find-debuginfo.c
libdwfl/gzip.c
libdwfl/image-header.c
libdwfl/libdwflP.h
libdwfl/lines.c
libdwfl/linux-core-attach.c
libdwfl/linux-pid-attach.c
libdwfl/linux-proc-maps.c
libdwfl/offline.c
libdwfl/open.c
libdwfl/relocate.c
libdwfl/segment.c
libelf/ChangeLog
libelf/libelfP.h

index 84290f79dd22d59cfd8a3ed1f7d1bec9d6c79f88..8cac7afb3522cebe6fdd9b509c4ae2f413a41755 100644 (file)
@@ -1,3 +1,8 @@
+2017-04-20  Ulf Hermann  <ulf.hermann@qt.io>
+
+       * crc32.c: include config.h.
+       * system.h: Don't include config.h.
+
 2017-02-16  Ulf Hermann  <ulf.hermann@qt.io>
 
        * Makefile.am (libeu_a_SOURCES): Remove version.c, add printversion.c
index 1a76b1b373fdf3404a81fad95aacf322b5547930..758602ea02fd210a2ad9da66939df7fc3e086235 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#if HAVE_CONFIG_H
+#include <config.h>
+#endif
+
 #include <stdint.h>
 #include "system.h"
 
index 2d05702502e4767375974bdfa4bd8de63b1fef75..9203335522daf952e3482f3cef91677c664cb3e1 100644 (file)
 #ifndef LIB_SYSTEM_H
 #define LIB_SYSTEM_H   1
 
-#ifdef HAVE_CONFIG_H
-# include <config.h>
-#endif
-
 #include <errno.h>
 #include <stddef.h>
 #include <stdint.h>
index b9be1bce19f2d0f932cfa484c04e3d99528450f6..1fc9da69d479d0a40600cef2cdadaf1145051c3d 100644 (file)
@@ -1,3 +1,61 @@
+2017-04-20  Ulf Hermann  <ulf.hermann@qt.io>
+
+       * libdwflP.h: Don't include config.h.
+       * argp-std.c: Include config.h.
+       * cu.c: Likewise.
+       * derelocate.c: Likewise.
+       * dwfl_addrdie.c: Likewise.
+       * dwfl_addrdwarf.c: Likewise.
+       * dwfl_addrmodule.c: Likewise.
+       * dwfl_begin.c: Likewise.
+       * dwfl_build_id_find_debuginfo.c: Likewise.
+       * dwfl_build_id_find_elf.c: Likewise.
+       * dwfl_cumodule.c: Likewise.
+       * dwfl_dwarf_line.c: Likewise.
+       * dwfl_end.c: Likewise.
+       * dwfl_frame.c: Likewise.
+       * dwfl_frame_regs.c: Likewise.
+       * dwfl_getdwarf.c: Likewise.
+       * dwfl_getmodules.c: Likewise.
+       * dwfl_getsrc.c: Likewise.
+       * dwfl_getsrclines.c: Likewise.
+       * dwfl_line_comp_dir.c: Likewise.
+       * dwfl_linecu.c: Likewise.
+       * dwfl_lineinfo.c: Likewise.
+       * dwfl_linemodule.c: Likewise.
+       * dwfl_module.c: Likewise.
+       * dwfl_module_addrdie.c: Likewise.
+       * dwfl_module_addrname.c: Likewise.
+       * dwfl_module_addrsym.c: Likewise.
+       * dwfl_module_build_id.c: Likewise.
+       * dwfl_module_dwarf_cfi.c: Likewise.
+       * dwfl_module_eh_cfi.c: Likewise.
+       * dwfl_module_getdarf.c: Likewise.
+       * dwfl_module_getelf.c: Likewise.
+       * dwfl_module_getsrc.c: Likewise.
+       * dwfl_module_getsrc_file.c: Likewise.
+       * dwfl_module_getsym.c: Likewise.
+       * dwfl_module_info.c: Likewise.
+       * dwfl_module_nextcu.c: Likewise.
+       * dwfl_module_register_names.c: Likewise.
+       * dwfl_module_report_build_id.c: Likewise.
+       * dwfl_module_return_value_location.c: Likewise.
+       * dwfl_nextcu.c: Likewise.
+       * dwfl_onesrcline.c: Likewise.
+       * dwfl_report_elf.c: Likewise.
+       * dwfl_validate_address.c: Likewise.
+       * dwfl_version.c: Likewise.
+       * find-debuginfo.c: Likewise.
+       * gzip.c: Likewise.
+       * image-header.c: Likewise.
+       * lines.c: Likewise.
+       * linux-core-attach.c: Likewise.
+       * linux-pid-attach.c: Likewise.
+       * offline.c: Likewise.
+       * open.c: Likewise.
+       * relocate.c: Likewise.
+       * segment.c: Likewise.
+
 2017-04-20  Ulf Hermann  <ulf.hermann@qt.io>
 
        * libdwfl.h: Use __const_attribute__.
index 501530a5b8acdb98f3a991b0e1b8b1a6974df73f..347a05b4038c6be4601ede922c236032129426e7 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <argp.h>
 #include <stdlib.h>
index 5182054d3e16aca6404a7bf391e8f5835491d351..7aa23b5010df098971dedbfddabc6fea1075aa4f 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "../libdw/libdwP.h"
 #include "../libdw/memory-access.h"
index 439a24e3b88d0247e280f2f1954de7480498ba26..e5c3e12e1f65fda00b9186b2496174ca3b0c170a 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 struct dwfl_relocation
index 1e9b3ab64e02c69adb99d46d57b0a03a22100a29..c5b1d68ef90cf53dfaf61ae68fb400a0dbcf276c 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwarf_Die *
index ba412eca6826689b03a4c27bad055b5e357e3e87..4f9efabf57107f5284e0e1f3036d48104fbbaedb 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwarf *
index 9234eb713b0cdef2416217a41ba4ab353e4d8e68..abf1ff484b19a16724ee6c112d715dd0d7a18738 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwfl_Module *
index 44c16a9212b8b971f9c2e119116bbae5540eb4a3..b03f5cf4b339c1439b1d149851ced80bac5c10d6 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwfl *
index f1c64bcd590ee7769087517a86586a63ab91359a..273e5e5f1d02f8882b9832f32e296f53238f344e 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <unistd.h>
 
index d4737c9f1d638d3ef9c4be1085f4383bd676b074..ee0c16468e85b1626db70dc2f459c778a387c0d6 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <inttypes.h>
 #include <fcntl.h>
index c5cf004daa8b8a1dc5223089deba0c588944c3f5..2b593f226628e4138c6b3e674ad110f443d60c6b 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwfl_Module *
index e96f859af9af24cf50d8d63fd25d933a9425623d..e22e984c5029f9e3c077fd382ae95234010930b3 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "../libdw/libdwP.h"
 
index 0b35bd28278cfb3ee40019fa9cf23bf9bc9f180d..74ee9e07244fd5022b2bd68c95e6544198933997 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <unistd.h>
 
index 1dc0c8dd3e92a052a74ec77fdb23ac03c5de0d7a..881f735af24d71dd38647c1f8932a109d21321df 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <unistd.h>
 
index 10803fe73f7501df3b0191493256a7e410f2efe1..83b1abef1f59ae2a207067e8c7f7f2ea6ef6c591 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 bool
index 8d1d9ba7919ce97c8e9dc84e02ebad488d9be5cb..edd088eca0d6fcfadf3125f052c238126dc29105 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 struct module_callback_info
index eed9b4ff2a955c5351d5e969dc2b3af56768ff5d..243cb04d667c793e1bef70bd17f13f6b2ee86ac5 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 ptrdiff_t
index 8d4ae02246dbe0835e7aac8669f7f93ac04a2b61..d853aed471aec940a738a235bf1f92d5973a0150 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwfl_Line *
index bdfcf5c6a0fead6a5a070f1a8e8568b523152f19..1ce78fcb70b93a20116335052821750d1d32b1b7 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 int
index bda09c466d2371c041716b861795b695cb887825..77c3fdf154c8c248cce525738f5e42a02d376b15 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <dwarf.h>
 
index ce78d297cdf701821d77ceec743dcc01bb118215..2043b17fda0b469f7aa8c1c35a3d6c0861229285 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 #undef dwfl_linecu
index 7ddbfb07f1d05c621f8a34d5300234443edc1b77..961871287822b96a9ea2d5b21525cc7275c40149 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "../libdw/libdwP.h"
 
index e4a35e096b4f5dd8bad7781c9a92893ae85f690b..d243f0d2188785076de174e8afcc781ab93b0051 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwfl_Module *
index 515092f3399175ed9e16db11f613aeaedf22dd79..510bd6910d26ee0d1fb82489caa4418b8b3dcbce 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "../libdw/cfi.h"
 #include <search.h>
index 20d2842a057cc6e774c50cbe7341a1b0be84dc72..b44ec139afc49ac2f362f3faa69ee3e90ded040d 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwarf_Die *
index 88a8139dd52725fdf10f801f8293154fd31beb54..3142b3eb2884cbbc65e535372568ae1fc33bdb08 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 const char *
index 5a7bf71459a966cd80ab313a22044b1b88f767af..db302e63676f0fee1e12f6bd545a8c292e519131 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 struct search_state
index c9a42ca72117f65765e3d16c9faab30eaae30554..6ca937613116be1d9b0244cdbf6dd748412bc965 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 static int
index 1dac26d5aca4d8cff4b9df60999f25d4765b765c..0e5b435615967acb0004eff7c64271541ab27f22 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "../libdw/cfi.h"
 
index dbe43b0f58d3dbd9ab4ae30f4952999d304b67ae..c296e399714860886ccd55ea7996ecbe4c0d67bd 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "../libdw/cfi.h"
 
index c8b839dcd79ca39bd5e39fa6c93cfa9a945f930f..9775aced3d2d6af7eb12f085bdb8bfdd3e403ba3 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <inttypes.h>
 #include <fcntl.h>
index f20fb0429f6a68f73e0fa3288375195dc6d8f52a..6358de4c1b1b8ba881241032e8489dfbd277195d 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Elf *
index f7e340bc687bd9b3de6e432508bb02880803cb89..fc99b163ed48e923139e828acdd687f03c8fe637 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "../libdw/libdwP.h"
 
index 4eaaeaffaf60b3167f98003faf3568cf2b36d8f3..cea2ba4145698f21bd365300bbe7bd890a768f52 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "../libdw/libdwP.h"
 
index 42d2b6792eb19d53327ab91e35ac8ff191476bba..8de9a3eb8092ee8eb547ee7d7e10b54b8c804038 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 const char *
index df16be4193ed5d83e11e88a95f7655b923ee5c83..af1faab403d534470a11dd856135f886d726b4d3 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 const char *
index 6f81f4ccfe64139a33e7ed565dc0857fe44ee92b..32ee6bc259fbf3584eb1605d7ca3612c052ed8fe 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwarf_Die *
index 18fed3733248d14f34e713ff513d52a0bdda60d0..9ea093711d359445849cb792ba827593d2622fd3 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 
index b41512b4d6ec51af83f00fbbbc312992828e26a6..31e17c863f5f19de0015cf2d0b04fd5c2e17db1b 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 // XXX vs report changed module: punting old file
index 29da61fb101a14b4f9979d948e03904f30c67ee7..ff6f56f81d16e2b17742f2bdeb1cc9866c25af20 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 
index 9ea83881b3b0125b89577704cb8a3b01ce046a24..64bd5219587a9d60371ff0055e3ae46639b21402 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwarf_Die *
index 4c20d6578a954cc87e1f36555e1fa1ba17c5bf9d..b1e7055545a8e70a7a73827e12213249a9d5920d 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 Dwfl_Line *
index 73a5511a8012cb3f330d04d305a9b977250d04dd..6950a37b4dc4d263833b5de6b374518c175720fd 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <fcntl.h>
 #include <unistd.h>
index 7334c3e27546b5b480983bac0579289b98bede67..15e2602a9383b0ac97dede93021851fc18fd75ac 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 int
index d1c5d9180ba7a553aea0b93ec707112e3b7843bd..c27d4f6de57a505e81af124f2c95202c6515a78a 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 const char *
index 80515dbd8b3d66fdbaae14361bcc25134e225e2b..6d5a42a6dd0cd1cbe1b9a81f1dbbe3b76c0c18d3 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <stdio.h>
 #include <fcntl.h>
index 078e1da488c0d612a370ee29cf4820e479216f83..c2c13bafb50fc1a1743e9591e282ae40e482ceb9 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "system.h"
 
index 62ccc3e35979ba1c23921d5d14ec6aa5bbe88f9a..25fbfd999c8139b978061979512a827410535034 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "system.h"
 
index 2a83646e3f603724a67a0f4c3a1d6ef4b43b394b..7d5f795cbf4d3597e1c2acf5631520f33b6982e1 100644 (file)
@@ -29,9 +29,6 @@
 #ifndef _LIBDWFLP_H
 #define _LIBDWFLP_H    1
 
-#ifndef PACKAGE_NAME
-# include <config.h>
-#endif
 #include <libdwfl.h>
 #include <libebl.h>
 #include <assert.h>
index 721e29ccdcbee5d533856c193aa2534342b5e20a..128c0c977e698af6ceebe514027abc07f6b0afaa 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include "../libdw/libdwP.h"
 
index f82ed03219952059ef70b24c1df01bd18b8640a6..9f05f72a0695e834191eb66beaec86e089d96118 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <fcntl.h>
 #include "system.h"
index 398df96d0712f0f562c574e143309bf72df6dca9..e6a5c419cc2aae7d6136eb43b1b0a57bbf8f1dcf 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libelfP.h"
 #include "libdwflP.h"
 #include <sys/types.h>
index 094dd53daea3d76ac2e7ba273516a589dbc2ca51..c4438c0f9534dcf1c48f1cb5fd032116d93ba006 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <inttypes.h>
 #include <sys/types.h>
index c0a259926a270d71dc99678470cd24c8b4e1d85a..80c80a168e3625e7d2e481d8822546b95fa8e530 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 #include <fcntl.h>
 #include <unistd.h>
index 92f2798b4074ba227582f24f6f9d42513920f7f1..4e0461bd2a9e89fae926d44195f49dca95f83789 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "../libelf/libelfP.h"
 #undef _
 #include "libdwflP.h"
index a44126e82235c6c12a0844789a80f68c36b210d1..17682433563bafea9d6ab1b57a33e5d0f30662a3 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 typedef uint8_t GElf_Byte;
index 2983cf232cf0a53868fb9e181ba0f176d77c859f..d9599a7fdbd352626027c7dd9329ae25c1516fb9 100644 (file)
    the GNU Lesser General Public License along with this program.  If
    not, see <http://www.gnu.org/licenses/>.  */
 
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
 #include "libdwflP.h"
 
 GElf_Addr
index 3772c6d175f5f67b965fb44c679b74cf1ddc8797..594bec995160905824dd424c1a50fe05a24a9ab0 100644 (file)
@@ -1,3 +1,7 @@
+2017-04-20  Ulf Hermann  <ulf.hermann@qt.io>
+
+       * libelfP.h: Don't include config.h.
+
 2017-04-20  Ulf Hermann  <ulf.hermann@qt.io>
 
        * elf_begin.c: Use F_GETFD rather than F_GETFL.
index 44599827e3ffd4ebe54c4574180cedee73457336..7ee6625a45ae18c4b64985f919785bbe65397bcf 100644 (file)
 #ifndef _LIBELFP_H
 #define _LIBELFP_H 1
 
-#ifdef HAVE_CONFIG_H
-# include <config.h>
-#endif
-
 #include <ar.h>
 #include <gelf.h>