Skip to content

Commit

Permalink
lang/gcc*: fix build with CPUTYPE?=g[3-5]
Browse files Browse the repository at this point in the history
GCC does not accept -mcpu=g4, but does accept -mcpu=G4.
  • Loading branch information
pkubaj committed Jun 19, 2023
1 parent 1b45869 commit 91117ec
Show file tree
Hide file tree
Showing 9 changed files with 45 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lang/gcc10/Makefile
Expand Up @@ -52,6 +52,11 @@ MULTILIB_CONFIGURE_ENABLE= multilib
CONFIGURE_ARGS+= --disable-multilib
.endif

.if defined(CPUTYPE) && ${CPUTYPE:Mg[3-5]}
CFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
CXXFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
.endif

.include <bsd.port.pre.mk>

.if ${ARCH} == amd64
Expand Down
5 changes: 5 additions & 0 deletions lang/gcc11-devel/Makefile
Expand Up @@ -66,6 +66,11 @@ MULTILIB_CONFIGURE_ENABLE= multilib
CONFIGURE_ARGS+= --disable-multilib
.endif

.if defined(CPUTYPE) && ${CPUTYPE:Mg[3-5]}
CFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
CXXFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
.endif

.include <bsd.port.pre.mk>

.if ${ARCH} == amd64
Expand Down
5 changes: 5 additions & 0 deletions lang/gcc11/Makefile
Expand Up @@ -60,6 +60,11 @@ MULTILIB_CONFIGURE_ENABLE= multilib
CONFIGURE_ARGS+= --disable-multilib
.endif

.if defined(CPUTYPE) && ${CPUTYPE:Mg[3-5]}
CFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
CXXFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
.endif

.include <bsd.port.pre.mk>

# Extraction fails with poudriere on aarch64 for GCC 11.
Expand Down
5 changes: 5 additions & 0 deletions lang/gcc12-devel/Makefile
Expand Up @@ -66,6 +66,11 @@ MULTILIB_CONFIGURE_ENABLE= multilib
CONFIGURE_ARGS+= --disable-multilib
.endif

.if defined(CPUTYPE) && ${CPUTYPE:Mg[3-5]}
CFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
CXXFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
.endif

.include <bsd.port.pre.mk>

.if ${ARCH} == amd64
Expand Down
5 changes: 5 additions & 0 deletions lang/gcc13-devel/Makefile
Expand Up @@ -66,6 +66,11 @@ MULTILIB_CONFIGURE_ENABLE= multilib
CONFIGURE_ARGS+= --disable-multilib
.endif

.if defined(CPUTYPE) && ${CPUTYPE:Mg[3-5]}
CFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
CXXFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
.endif

.include <bsd.port.pre.mk>

.if ${ARCH} == amd64
Expand Down
5 changes: 5 additions & 0 deletions lang/gcc13/Makefile
Expand Up @@ -61,6 +61,11 @@ MULTILIB_CONFIGURE_ENABLE= multilib
CONFIGURE_ARGS+= --disable-multilib
.endif

.if defined(CPUTYPE) && ${CPUTYPE:Mg[3-5]}
CFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
CXXFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
.endif

.include <bsd.port.pre.mk>

.if ${ARCH} == amd64
Expand Down
5 changes: 5 additions & 0 deletions lang/gcc14-devel/Makefile
Expand Up @@ -64,6 +64,11 @@ MULTILIB_CONFIGURE_ENABLE= multilib
CONFIGURE_ARGS+= --disable-multilib
.endif

.if defined(CPUTYPE) && ${CPUTYPE:Mg[3-5]}
CFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
CXXFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
.endif

.include <bsd.port.pre.mk>

.if ${ARCH} == amd64
Expand Down
5 changes: 5 additions & 0 deletions lang/gcc8/Makefile
Expand Up @@ -50,6 +50,11 @@ MULTILIB_CONFIGURE_ENABLE= multilib
CONFIGURE_ARGS+= --disable-multilib
.endif

.if defined(CPUTYPE) && ${CPUTYPE:Mg[3-5]}
CFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
CXXFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
.endif

.include <bsd.port.pre.mk>

.if ${ARCH} == amd64
Expand Down
5 changes: 5 additions & 0 deletions lang/gcc9/Makefile
Expand Up @@ -54,6 +54,11 @@ MULTILIB_CONFIGURE_ENABLE= multilib
CONFIGURE_ARGS+= --disable-multilib
.endif

.if defined(CPUTYPE) && ${CPUTYPE:Mg[3-5]}
CFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
CXXFLAGS:= ${CFLAGS:S/mcpu=g/mcpu=G/}
.endif

.include <bsd.port.pre.mk>

.if ${ARCH} == amd64
Expand Down

0 comments on commit 91117ec

Please sign in to comment.