Skip to content

Commit

Permalink
gptfdisk: Use MacPorts CFLAGS and CXXFLAGS
Browse files Browse the repository at this point in the history
This allows the right C++ standard library and optimization flags to be
used.
  • Loading branch information
ryandesign committed Jun 4, 2018
1 parent 2785f1f commit 99811f0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
6 changes: 3 additions & 3 deletions sysutils/gptfdisk/Portfile
Expand Up @@ -4,6 +4,7 @@ PortSystem 1.0

name gptfdisk
version 1.0.3
revision 1
categories sysutils
platforms darwin
license GPL-2+
Expand All @@ -17,7 +18,6 @@ long_description GPT fdisk (gdisk) is a disk partitioning tool loosely mo
homepage http://www.rodsbooks.com/gdisk/
master_sites sourceforge:project/gptfdisk/gptfdisk/${version}


checksums md5 07b625a583b66c8c5840be5923f3e3fe \
sha1 9a74bbe7805d562316e92417f71e4b03155308e6 \
sha256 89fd5aec35c409d610a36cb49c65b442058565ed84042f767bba614b8fc91b5c \
Expand All @@ -35,8 +35,8 @@ depends_lib port:ncurses \
use_configure no

build.args -f Makefile.mac \
CC="${configure.cc}" \
CXX="${configure.cxx}" \
CC="${configure.cc} ${configure.cflags}" \
CXX="${configure.cxx} ${configure.cxxflags}" \
FATBINFLAGS="[get_canonical_archflags]"

destroot {
Expand Down
5 changes: 3 additions & 2 deletions sysutils/gptfdisk/files/patch-Makefile.mac.diff
Expand Up @@ -5,10 +5,11 @@
CC=gcc
CXX=clang++
FATBINFLAGS=-arch x86_64 -arch i386 -mmacosx-version-min=10.4
CFLAGS=$(FATBINFLAGS) -O2 -D_FILE_OFFSET_BITS=64 -g
-CFLAGS=$(FATBINFLAGS) -O2 -D_FILE_OFFSET_BITS=64 -g
-#CXXFLAGS=-O2 -Wall -D_FILE_OFFSET_BITS=64 -D USE_UTF16 -I/opt/local/include -I/usr/local/include -I/opt/local/include -g
-CXXFLAGS=$(FATBINFLAGS) -O2 -Wall -D_FILE_OFFSET_BITS=64 -I/opt/local/include -I /usr/local/include -I/opt/local/include -g
+CXXFLAGS=$(FATBINFLAGS) -O2 -Wall -D_FILE_OFFSET_BITS=64 -I$(prefix)/include -g
+CFLAGS=$(FATBINFLAGS) -D_FILE_OFFSET_BITS=64 -g
+CXXFLAGS=$(FATBINFLAGS) -Wall -D_FILE_OFFSET_BITS=64 -I$(prefix)/include -g
LIB_NAMES=crc32 support guid gptpart mbrpart basicmbr mbr gpt bsd parttypes attributes diskio diskio-unix
MBR_LIBS=support diskio diskio-unix basicmbr mbrpart
#LIB_SRCS=$(NAMES:=.cc)
Expand Down

0 comments on commit 99811f0

Please sign in to comment.