summaryrefslogtreecommitdiffstats
path: root/Source/cmELF.cxx
diff options
context:
space:
mode:
authorKitware Robot <kwrobot@kitware.com>2018-06-01 13:53:41 (GMT)
committerBrad King <brad.king@kitware.com>2018-06-01 13:53:42 (GMT)
commitd7204e649ed4ebb19bb341b4e49eb51514364922 (patch)
treed9ac3ded5ae6899be7188795011743fe3e6da0a6 /Source/cmELF.cxx
parent12fed3edb107c949671043196fa94c542b45452a (diff)
downloadCMake-d7204e649ed4ebb19bb341b4e49eb51514364922.zip
CMake-d7204e649ed4ebb19bb341b4e49eb51514364922.tar.gz
CMake-d7204e649ed4ebb19bb341b4e49eb51514364922.tar.bz2
Revise C++ coding style using clang-format-6.0
Run the `clang-format.bash` script to update all our C and C++ code to a new style defined by `.clang-format`. Use `clang-format` version 6.0. * If you reached this commit for a line in `git blame`, re-run the blame operation starting at the parent of this commit to see older history for the content. * See the parent commit for instructions to rebase a change across this style transition commit.
Diffstat (limited to 'Source/cmELF.cxx')
-rw-r--r--Source/cmELF.cxx41
1 files changed, 21 insertions, 20 deletions
diff --git a/Source/cmELF.cxx b/Source/cmELF.cxx
index 77ccd30..0ccd68a 100644
--- a/Source/cmELF.cxx
+++ b/Source/cmELF.cxx
@@ -13,39 +13,39 @@
// Include the ELF format information system header.
#if defined(__OpenBSD__)
-#include <elf_abi.h>
-#include <stdint.h>
+# include <elf_abi.h>
+# include <stdint.h>
#elif defined(__HAIKU__)
-#include <elf32.h>
-#include <elf64.h>
+# include <elf32.h>
+# include <elf64.h>
typedef struct Elf32_Ehdr Elf32_Ehdr;
typedef struct Elf32_Shdr Elf32_Shdr;
typedef struct Elf32_Sym Elf32_Sym;
typedef struct Elf32_Rel Elf32_Rel;
typedef struct Elf32_Rela Elf32_Rela;
-#define ELFMAG0 0x7F
-#define ELFMAG1 'E'
-#define ELFMAG2 'L'
-#define ELFMAG3 'F'
-#define ET_NONE 0
-#define ET_REL 1
-#define ET_EXEC 2
-#define ET_DYN 3
-#define ET_CORE 4
-#define EM_386 3
-#define EM_SPARC 2
-#define EM_PPC 20
+# define ELFMAG0 0x7F
+# define ELFMAG1 'E'
+# define ELFMAG2 'L'
+# define ELFMAG3 'F'
+# define ET_NONE 0
+# define ET_REL 1
+# define ET_EXEC 2
+# define ET_DYN 3
+# define ET_CORE 4
+# define EM_386 3
+# define EM_SPARC 2
+# define EM_PPC 20
#else
-#include <elf.h>
+# include <elf.h>
#endif
#if defined(__sun)
-#include <sys/link.h> // For dynamic section information
+# include <sys/link.h> // For dynamic section information
#endif
#ifdef _SCO_DS
-#include <link.h> // For DT_SONAME etc.
+# include <link.h> // For DT_SONAME etc.
#endif
#ifndef DT_RUNPATH
-#define DT_RUNPATH 29
+# define DT_RUNPATH 29
#endif
// Low-level byte swapping implementation.
@@ -162,6 +162,7 @@ public:
// Return the recorded ELF type.
cmELF::FileType GetFileType() const { return this->ELFType; }
+
protected:
// Data common to all ELF class implementations.