diff mbox

[PATCHv2] linux-generic: Makefile.am: fix basename conflicts

Message ID 1438943024-26909-1-git-send-email-anders.roxell@linaro.org
State New
Headers show

Commit Message

Anders Roxell Aug. 7, 2015, 10:23 a.m. UTC
Building generated this warning message:
"copying selected object files to avoid basename conflicts..."

Reported-by: Mile Holmes <mike.holmes@linaro.org>
Signed-off-by: Anders Roxell <anders.roxell@linaro.org>
---

So resending this patch with minor changes.
* reduce the long filename with 6 chars (we like short names) =)
* Had to fix another random bug [1] before this patch could be applied.

Note: this patch will not apply without [1] applied first.

Cheers,
Anders

[1] https://lists.linaro.org/pipermail/lng-odp/2015-August/014015.html

Cheers,
Anders

 platform/linux-generic/Makefile.am                 |  8 ++---
 platform/linux-generic/arch/linux/odp_time.c       | 38 ----------------------
 .../linux-generic/arch/linux/odp_time_cycles.c     | 38 ++++++++++++++++++++++
 platform/linux-generic/arch/mips64/odp_time.c      | 21 ------------
 .../linux-generic/arch/mips64/odp_time_cycles.c    | 21 ++++++++++++
 platform/linux-generic/arch/x86/odp_time.c         | 23 -------------
 platform/linux-generic/arch/x86/odp_time_cycles.c  | 23 +++++++++++++
 7 files changed, 86 insertions(+), 86 deletions(-)
 delete mode 100644 platform/linux-generic/arch/linux/odp_time.c
 create mode 100644 platform/linux-generic/arch/linux/odp_time_cycles.c
 delete mode 100644 platform/linux-generic/arch/mips64/odp_time.c
 create mode 100644 platform/linux-generic/arch/mips64/odp_time_cycles.c
 delete mode 100644 platform/linux-generic/arch/x86/odp_time.c
 create mode 100644 platform/linux-generic/arch/x86/odp_time_cycles.c

Comments

Anders Roxell Aug. 7, 2015, 10:55 a.m. UTC | #1
On 7 August 2015 at 12:23, Anders Roxell <anders.roxell@linaro.org> wrote:
> Building generated this warning message:
> "copying selected object files to avoid basename conflicts..."
>
> Reported-by: Mile Holmes <mike.holmes@linaro.org>
> Signed-off-by: Anders Roxell <anders.roxell@linaro.org>

Resending v3 with the -M flag...

Cheers,
Anders

> ---
>
> So resending this patch with minor changes.
> * reduce the long filename with 6 chars (we like short names) =)
> * Had to fix another random bug [1] before this patch could be applied.
>
> Note: this patch will not apply without [1] applied first.
>
> Cheers,
> Anders
>
> [1] https://lists.linaro.org/pipermail/lng-odp/2015-August/014015.html
>
> Cheers,
> Anders
>
>  platform/linux-generic/Makefile.am                 |  8 ++---
>  platform/linux-generic/arch/linux/odp_time.c       | 38 ----------------------
>  .../linux-generic/arch/linux/odp_time_cycles.c     | 38 ++++++++++++++++++++++
>  platform/linux-generic/arch/mips64/odp_time.c      | 21 ------------
>  .../linux-generic/arch/mips64/odp_time_cycles.c    | 21 ++++++++++++
>  platform/linux-generic/arch/x86/odp_time.c         | 23 -------------
>  platform/linux-generic/arch/x86/odp_time_cycles.c  | 23 +++++++++++++
>  7 files changed, 86 insertions(+), 86 deletions(-)
>  delete mode 100644 platform/linux-generic/arch/linux/odp_time.c
>  create mode 100644 platform/linux-generic/arch/linux/odp_time_cycles.c
>  delete mode 100644 platform/linux-generic/arch/mips64/odp_time.c
>  create mode 100644 platform/linux-generic/arch/mips64/odp_time_cycles.c
>  delete mode 100644 platform/linux-generic/arch/x86/odp_time.c
>  create mode 100644 platform/linux-generic/arch/x86/odp_time_cycles.c
>
> diff --git a/platform/linux-generic/Makefile.am b/platform/linux-generic/Makefile.am
> index c0f7220..ed4add5 100644
> --- a/platform/linux-generic/Makefile.am
> +++ b/platform/linux-generic/Makefile.am
> @@ -160,9 +160,9 @@ __LIB__libodp_la_SOURCES = \
>                            odp_timer.c \
>                            odp_version.c \
>                            odp_weak.c \
> -                          arch/@ARCH@/odp_time.c
> +                          arch/@ARCH@/odp_time_cycles.c
>
>  EXTRA_DIST = \
> -            arch/linux/odp_time.c \
> -            arch/mips64/odp_time.c \
> -            arch/x86/odp_time.c
> +            arch/linux/odp_time_cycles.c \
> +            arch/mips64/odp_time_cycles.c \
> +            arch/x86/odp_time_cycles.c
> diff --git a/platform/linux-generic/arch/linux/odp_time.c b/platform/linux-generic/arch/linux/odp_time.c
> deleted file mode 100644
> index 4dc0764..0000000
> --- a/platform/linux-generic/arch/linux/odp_time.c
> +++ /dev/null
> @@ -1,38 +0,0 @@
> -/* Copyright (c) 2015, Linaro Limited
> - * All rights reserved.
> - *
> - * SPDX-License-Identifier:     BSD-3-Clause
> - */
> -
> -#define _POSIX_C_SOURCE 199309L
> -
> -#include <stdlib.h>
> -#include <time.h>
> -
> -#include <odp/time.h>
> -#include <odp/hints.h>
> -#include <odp/system_info.h>
> -#include <odp_debug_internal.h>
> -
> -#define GIGA 1000000000
> -
> -uint64_t odp_time_cycles(void)
> -{
> -       struct timespec time;
> -       uint64_t sec, ns, hz, cycles;
> -       int ret;
> -
> -       ret = clock_gettime(CLOCK_MONOTONIC_RAW, &time);
> -
> -       if (ret != 0)
> -               ODP_ABORT("clock_gettime failed\n");
> -
> -       hz  = odp_sys_cpu_hz();
> -       sec = (uint64_t) time.tv_sec;
> -       ns  = (uint64_t) time.tv_nsec;
> -
> -       cycles  = sec * hz;
> -       cycles += (ns * hz) / GIGA;
> -
> -       return cycles;
> -}
> diff --git a/platform/linux-generic/arch/linux/odp_time_cycles.c b/platform/linux-generic/arch/linux/odp_time_cycles.c
> new file mode 100644
> index 0000000..4dc0764
> --- /dev/null
> +++ b/platform/linux-generic/arch/linux/odp_time_cycles.c
> @@ -0,0 +1,38 @@
> +/* Copyright (c) 2015, Linaro Limited
> + * All rights reserved.
> + *
> + * SPDX-License-Identifier:     BSD-3-Clause
> + */
> +
> +#define _POSIX_C_SOURCE 199309L
> +
> +#include <stdlib.h>
> +#include <time.h>
> +
> +#include <odp/time.h>
> +#include <odp/hints.h>
> +#include <odp/system_info.h>
> +#include <odp_debug_internal.h>
> +
> +#define GIGA 1000000000
> +
> +uint64_t odp_time_cycles(void)
> +{
> +       struct timespec time;
> +       uint64_t sec, ns, hz, cycles;
> +       int ret;
> +
> +       ret = clock_gettime(CLOCK_MONOTONIC_RAW, &time);
> +
> +       if (ret != 0)
> +               ODP_ABORT("clock_gettime failed\n");
> +
> +       hz  = odp_sys_cpu_hz();
> +       sec = (uint64_t) time.tv_sec;
> +       ns  = (uint64_t) time.tv_nsec;
> +
> +       cycles  = sec * hz;
> +       cycles += (ns * hz) / GIGA;
> +
> +       return cycles;
> +}
> diff --git a/platform/linux-generic/arch/mips64/odp_time.c b/platform/linux-generic/arch/mips64/odp_time.c
> deleted file mode 100644
> index 4fb790b..0000000
> --- a/platform/linux-generic/arch/mips64/odp_time.c
> +++ /dev/null
> @@ -1,21 +0,0 @@
> -/* Copyright (c) 2015, Linaro Limited
> - * All rights reserved.
> - *
> - * SPDX-License-Identifier:     BSD-3-Clause
> - */
> -
> -#include <odp/time.h>
> -#include <odp/hints.h>
> -#include <odp/system_info.h>
> -
> -uint64_t odp_time_cycles(void)
> -{
> -       #define CVMX_TMP_STR(x) CVMX_TMP_STR2(x)
> -       #define CVMX_TMP_STR2(x) #x
> -       uint64_t cycle;
> -
> -       __asm__ __volatile__ ("rdhwr %[rt],$" CVMX_TMP_STR(31) :
> -                          [rt] "=d" (cycle) : : "memory");
> -
> -       return cycle;
> -}
> diff --git a/platform/linux-generic/arch/mips64/odp_time_cycles.c b/platform/linux-generic/arch/mips64/odp_time_cycles.c
> new file mode 100644
> index 0000000..4fb790b
> --- /dev/null
> +++ b/platform/linux-generic/arch/mips64/odp_time_cycles.c
> @@ -0,0 +1,21 @@
> +/* Copyright (c) 2015, Linaro Limited
> + * All rights reserved.
> + *
> + * SPDX-License-Identifier:     BSD-3-Clause
> + */
> +
> +#include <odp/time.h>
> +#include <odp/hints.h>
> +#include <odp/system_info.h>
> +
> +uint64_t odp_time_cycles(void)
> +{
> +       #define CVMX_TMP_STR(x) CVMX_TMP_STR2(x)
> +       #define CVMX_TMP_STR2(x) #x
> +       uint64_t cycle;
> +
> +       __asm__ __volatile__ ("rdhwr %[rt],$" CVMX_TMP_STR(31) :
> +                          [rt] "=d" (cycle) : : "memory");
> +
> +       return cycle;
> +}
> diff --git a/platform/linux-generic/arch/x86/odp_time.c b/platform/linux-generic/arch/x86/odp_time.c
> deleted file mode 100644
> index a111561..0000000
> --- a/platform/linux-generic/arch/x86/odp_time.c
> +++ /dev/null
> @@ -1,23 +0,0 @@
> -/* Copyright (c) 2015, Linaro Limited
> - * All rights reserved.
> - *
> - * SPDX-License-Identifier:     BSD-3-Clause
> - */
> -#include <odp/time.h>
> -
> -uint64_t odp_time_cycles(void)
> -{
> -       union {
> -               uint64_t tsc_64;
> -               struct {
> -                       uint32_t lo_32;
> -                       uint32_t hi_32;
> -               };
> -       } tsc;
> -
> -       __asm__ __volatile__ ("rdtsc" :
> -                    "=a" (tsc.lo_32),
> -                    "=d" (tsc.hi_32) : : "memory");
> -
> -       return tsc.tsc_64;
> -}
> diff --git a/platform/linux-generic/arch/x86/odp_time_cycles.c b/platform/linux-generic/arch/x86/odp_time_cycles.c
> new file mode 100644
> index 0000000..a111561
> --- /dev/null
> +++ b/platform/linux-generic/arch/x86/odp_time_cycles.c
> @@ -0,0 +1,23 @@
> +/* Copyright (c) 2015, Linaro Limited
> + * All rights reserved.
> + *
> + * SPDX-License-Identifier:     BSD-3-Clause
> + */
> +#include <odp/time.h>
> +
> +uint64_t odp_time_cycles(void)
> +{
> +       union {
> +               uint64_t tsc_64;
> +               struct {
> +                       uint32_t lo_32;
> +                       uint32_t hi_32;
> +               };
> +       } tsc;
> +
> +       __asm__ __volatile__ ("rdtsc" :
> +                    "=a" (tsc.lo_32),
> +                    "=d" (tsc.hi_32) : : "memory");
> +
> +       return tsc.tsc_64;
> +}
> --
> 2.1.4
>
diff mbox

Patch

diff --git a/platform/linux-generic/Makefile.am b/platform/linux-generic/Makefile.am
index c0f7220..ed4add5 100644
--- a/platform/linux-generic/Makefile.am
+++ b/platform/linux-generic/Makefile.am
@@ -160,9 +160,9 @@  __LIB__libodp_la_SOURCES = \
 			   odp_timer.c \
 			   odp_version.c \
 			   odp_weak.c \
-			   arch/@ARCH@/odp_time.c
+			   arch/@ARCH@/odp_time_cycles.c
 
 EXTRA_DIST = \
-	     arch/linux/odp_time.c \
-	     arch/mips64/odp_time.c \
-	     arch/x86/odp_time.c
+	     arch/linux/odp_time_cycles.c \
+	     arch/mips64/odp_time_cycles.c \
+	     arch/x86/odp_time_cycles.c
diff --git a/platform/linux-generic/arch/linux/odp_time.c b/platform/linux-generic/arch/linux/odp_time.c
deleted file mode 100644
index 4dc0764..0000000
--- a/platform/linux-generic/arch/linux/odp_time.c
+++ /dev/null
@@ -1,38 +0,0 @@ 
-/* Copyright (c) 2015, Linaro Limited
- * All rights reserved.
- *
- * SPDX-License-Identifier:     BSD-3-Clause
- */
-
-#define _POSIX_C_SOURCE 199309L
-
-#include <stdlib.h>
-#include <time.h>
-
-#include <odp/time.h>
-#include <odp/hints.h>
-#include <odp/system_info.h>
-#include <odp_debug_internal.h>
-
-#define GIGA 1000000000
-
-uint64_t odp_time_cycles(void)
-{
-	struct timespec time;
-	uint64_t sec, ns, hz, cycles;
-	int ret;
-
-	ret = clock_gettime(CLOCK_MONOTONIC_RAW, &time);
-
-	if (ret != 0)
-		ODP_ABORT("clock_gettime failed\n");
-
-	hz  = odp_sys_cpu_hz();
-	sec = (uint64_t) time.tv_sec;
-	ns  = (uint64_t) time.tv_nsec;
-
-	cycles  = sec * hz;
-	cycles += (ns * hz) / GIGA;
-
-	return cycles;
-}
diff --git a/platform/linux-generic/arch/linux/odp_time_cycles.c b/platform/linux-generic/arch/linux/odp_time_cycles.c
new file mode 100644
index 0000000..4dc0764
--- /dev/null
+++ b/platform/linux-generic/arch/linux/odp_time_cycles.c
@@ -0,0 +1,38 @@ 
+/* Copyright (c) 2015, Linaro Limited
+ * All rights reserved.
+ *
+ * SPDX-License-Identifier:     BSD-3-Clause
+ */
+
+#define _POSIX_C_SOURCE 199309L
+
+#include <stdlib.h>
+#include <time.h>
+
+#include <odp/time.h>
+#include <odp/hints.h>
+#include <odp/system_info.h>
+#include <odp_debug_internal.h>
+
+#define GIGA 1000000000
+
+uint64_t odp_time_cycles(void)
+{
+	struct timespec time;
+	uint64_t sec, ns, hz, cycles;
+	int ret;
+
+	ret = clock_gettime(CLOCK_MONOTONIC_RAW, &time);
+
+	if (ret != 0)
+		ODP_ABORT("clock_gettime failed\n");
+
+	hz  = odp_sys_cpu_hz();
+	sec = (uint64_t) time.tv_sec;
+	ns  = (uint64_t) time.tv_nsec;
+
+	cycles  = sec * hz;
+	cycles += (ns * hz) / GIGA;
+
+	return cycles;
+}
diff --git a/platform/linux-generic/arch/mips64/odp_time.c b/platform/linux-generic/arch/mips64/odp_time.c
deleted file mode 100644
index 4fb790b..0000000
--- a/platform/linux-generic/arch/mips64/odp_time.c
+++ /dev/null
@@ -1,21 +0,0 @@ 
-/* Copyright (c) 2015, Linaro Limited
- * All rights reserved.
- *
- * SPDX-License-Identifier:     BSD-3-Clause
- */
-
-#include <odp/time.h>
-#include <odp/hints.h>
-#include <odp/system_info.h>
-
-uint64_t odp_time_cycles(void)
-{
-	#define CVMX_TMP_STR(x) CVMX_TMP_STR2(x)
-	#define CVMX_TMP_STR2(x) #x
-	uint64_t cycle;
-
-	__asm__ __volatile__ ("rdhwr %[rt],$" CVMX_TMP_STR(31) :
-			   [rt] "=d" (cycle) : : "memory");
-
-	return cycle;
-}
diff --git a/platform/linux-generic/arch/mips64/odp_time_cycles.c b/platform/linux-generic/arch/mips64/odp_time_cycles.c
new file mode 100644
index 0000000..4fb790b
--- /dev/null
+++ b/platform/linux-generic/arch/mips64/odp_time_cycles.c
@@ -0,0 +1,21 @@ 
+/* Copyright (c) 2015, Linaro Limited
+ * All rights reserved.
+ *
+ * SPDX-License-Identifier:     BSD-3-Clause
+ */
+
+#include <odp/time.h>
+#include <odp/hints.h>
+#include <odp/system_info.h>
+
+uint64_t odp_time_cycles(void)
+{
+	#define CVMX_TMP_STR(x) CVMX_TMP_STR2(x)
+	#define CVMX_TMP_STR2(x) #x
+	uint64_t cycle;
+
+	__asm__ __volatile__ ("rdhwr %[rt],$" CVMX_TMP_STR(31) :
+			   [rt] "=d" (cycle) : : "memory");
+
+	return cycle;
+}
diff --git a/platform/linux-generic/arch/x86/odp_time.c b/platform/linux-generic/arch/x86/odp_time.c
deleted file mode 100644
index a111561..0000000
--- a/platform/linux-generic/arch/x86/odp_time.c
+++ /dev/null
@@ -1,23 +0,0 @@ 
-/* Copyright (c) 2015, Linaro Limited
- * All rights reserved.
- *
- * SPDX-License-Identifier:     BSD-3-Clause
- */
-#include <odp/time.h>
-
-uint64_t odp_time_cycles(void)
-{
-	union {
-		uint64_t tsc_64;
-		struct {
-			uint32_t lo_32;
-			uint32_t hi_32;
-		};
-	} tsc;
-
-	__asm__ __volatile__ ("rdtsc" :
-		     "=a" (tsc.lo_32),
-		     "=d" (tsc.hi_32) : : "memory");
-
-	return tsc.tsc_64;
-}
diff --git a/platform/linux-generic/arch/x86/odp_time_cycles.c b/platform/linux-generic/arch/x86/odp_time_cycles.c
new file mode 100644
index 0000000..a111561
--- /dev/null
+++ b/platform/linux-generic/arch/x86/odp_time_cycles.c
@@ -0,0 +1,23 @@ 
+/* Copyright (c) 2015, Linaro Limited
+ * All rights reserved.
+ *
+ * SPDX-License-Identifier:     BSD-3-Clause
+ */
+#include <odp/time.h>
+
+uint64_t odp_time_cycles(void)
+{
+	union {
+		uint64_t tsc_64;
+		struct {
+			uint32_t lo_32;
+			uint32_t hi_32;
+		};
+	} tsc;
+
+	__asm__ __volatile__ ("rdtsc" :
+		     "=a" (tsc.lo_32),
+		     "=d" (tsc.hi_32) : : "memory");
+
+	return tsc.tsc_64;
+}