summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Macy <mmacy@FreeBSD.org>2018-05-31 22:26:55 +0000
committerMatt Macy <mmacy@FreeBSD.org>2018-05-31 22:26:55 +0000
commit7d1c2b74a03e621f235e2cf282bf724259f364c5 (patch)
treee39bdc1145a8ff81b2a3ee714c566c5a71a03575
parent785dd70da883fc4d78687fc153e6f03ace6b8c9d (diff)
Notes
-rw-r--r--Makefile.inc12
-rw-r--r--Makefile.libcompat2
-rw-r--r--lib/libpmc/Makefile8
-rw-r--r--lib/libpmc/libpmc_pmu_util.c2
4 files changed, 7 insertions, 7 deletions
diff --git a/Makefile.inc1 b/Makefile.inc1
index 0419a3cbafeac..efc55be7cde04 100644
--- a/Makefile.inc1
+++ b/Makefile.inc1
@@ -2030,7 +2030,7 @@ _tcsh=bin/csh
_libmagic=lib/libmagic
.endif
-.if ${TARGET_ARCH} == "amd64"
+.if ${TARGET_ARCH} == "amd64" || ${TARGET_ARCH} == "i386"
_jevents=lib/libpmc/pmu-events
.endif
diff --git a/Makefile.libcompat b/Makefile.libcompat
index 35d804e9f6509..52928e87d296a 100644
--- a/Makefile.libcompat
+++ b/Makefile.libcompat
@@ -192,7 +192,7 @@ build${libcompat}: .PHONY
DIRPRFX=${_dir}/ ${_t}
.endfor
.endfor
-.for _dir in lib/ncurses/ncurses lib/ncurses/ncursesw lib/libmagic
+.for _dir in lib/ncurses/ncurses lib/ncurses/ncursesw lib/libmagic lib/libpmc/pmu-events
${_+_}cd ${.CURDIR}/${_dir}; \
WORLDTMP=${WORLDTMP} \
MAKEFLAGS="-m ${.CURDIR}/tools/build/mk ${.MAKEFLAGS}" \
diff --git a/lib/libpmc/Makefile b/lib/libpmc/Makefile
index 6eb2ad6863d24..d6e771a39f46e 100644
--- a/lib/libpmc/Makefile
+++ b/lib/libpmc/Makefile
@@ -8,13 +8,13 @@ INCS= pmc.h pmclog.h
CFLAGS+= -I${.CURDIR}
-.if ${MACHINE_CPUARCH} == "amd64"
+.if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386"
-.if ${MACHINE_CPUARCH} == "aarch64"
+.if ${MACHINE_ARCH} == "aarch64"
EVENT_ARCH="arm64"
-.elif ${MACHINE_CPUARCH} == "amd64"
+.elif ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386"
EVENT_ARCH="x86"
-.elif ${MACHINE_CPUARCH} == "powerpc"
+.elif ${MACHINE_ARCH} == "powerpc"
EVENT_ARCH="powerpc"
.endif
diff --git a/lib/libpmc/libpmc_pmu_util.c b/lib/libpmc/libpmc_pmu_util.c
index 9165caaa2855a..30565e9177d58 100644
--- a/lib/libpmc/libpmc_pmu_util.c
+++ b/lib/libpmc/libpmc_pmu_util.c
@@ -40,7 +40,7 @@
#include <libpmcstat.h>
#include "pmu-events/pmu-events.h"
-#if defined(__amd64__)
+#if defined(__amd64__) || defined(__i386__)
struct pmu_alias {
const char *pa_alias;
const char *pa_name;