summarylogtreecommitdiffstats
path: root/03.pgo.patch
diff options
context:
space:
mode:
authorQue Quotion2018-08-30 10:42:56 +0900
committerQue Quotion2018-08-30 10:49:02 +0900
commit00b4663035f5a907c5170253ce762f6df4ee7975 (patch)
tree39dc35e8b4b179f79a45c8a871ececa20a9154a5 /03.pgo.patch
parent32fa78c289e0c3f0ae564a73f2045de2dadb4ae5 (diff)
downloadaur-00b4663035f5a907c5170253ce762f6df4ee7975.tar.gz
Migrate makepkg-optimize2 into makepkg-optimize; this is the best way to deal with my out-of-date troll and pacman-build_env-ext
Diffstat (limited to '03.pgo.patch')
-rw-r--r--03.pgo.patch49
1 files changed, 0 insertions, 49 deletions
diff --git a/03.pgo.patch b/03.pgo.patch
deleted file mode 100644
index f81254b5f2d..00000000000
--- a/03.pgo.patch
+++ /dev/null
@@ -1,49 +0,0 @@
---- makepkg-optimize
-+++ makepkg-optimize
-@@ -877,6 +877,23 @@ run_build() {
- NMFLAGS+=" --plugin $LTOPLUGIN"
- fi
-
-+ # Generate or utilize pgo if it is requested (check buildenv and PKGBUILD opts)
-+ if check_buildoption "pgo" "y"; then
-+ if [ ! -d "$PROFDEST/$pkgbase.gen" ]; then
-+ mkdir "$PROFDEST/$pkgbase.gen"
-+ CFLAGS+=" -fprofile-generate -fprofile-dir=$PROFDEST/$pkgbase.gen"
-+ CXXFLAGS+=" -fprofile-generate -fprofile-dir=$PROFDEST/$pkgbase.gen"
-+ LDFLAGS+=" -lgcov"
-+ else
-+ [[ ! -d "$PROFDEST/$pkgbase.used" ]] && mv "$PROFDEST/$pkgbase.gen" "$PROFDEST/$pkgbase.used"
-+ #It is not necessary, and occasionally dangerous, to profile conftest.c
-+ [[ -f "$PROFDEST/$pkgbase.used/conftest.gcda" ]] && rm "$PROFDEST/$pkgbase.used/conftest.gcda"
-+ CFLAGS+=" -fprofile-correction -fprofile-use -fprofile-dir=$PROFDEST/$pkgbase.used"
-+ CXXFLAGS+=" -fprofile-correction -fprofile-use -fprofile-dir=$PROFDEST/$pkgbase.used"
-+ fi
-+ fi
-+
-+
- run_function_safe "build"
- }
-
-@@ -2012,6 +2027,7 @@ trap 'trap_exit USR1 "$(gettext "An unknown error has occurred. Exiting...")"' E
- # preserve environment variables and canonicalize path
- [[ -n ${PKGDEST} ]] && _PKGDEST=$(canonicalize_path ${PKGDEST})
- [[ -n ${SRCDEST} ]] && _SRCDEST=$(canonicalize_path ${SRCDEST})
-+[[ -n ${PROFDEST} ]] && _PROFDEST=$(canonicalize_path ${PROFDEST})
- [[ -n ${SRCPKGDEST} ]] && _SRCPKGDEST=$(canonicalize_path ${SRCPKGDEST})
- [[ -n ${LOGDEST} ]] && _LOGDEST=$(canonicalize_path ${LOGDEST})
- [[ -n ${BUILDDIR} ]] && _BUILDDIR=$(canonicalize_path ${BUILDDIR})
-@@ -2109,6 +2125,14 @@ if (( SOURCEONLY )); then
- IGNOREARCH=1
- fi
-
-+PROFDEST=${_PROFDEST:-$PROFDEST}
-+PROFDEST=${PROFDEST:-$startdir} #default to $startdir if undefined
-+if [[ ! -w $PROFDEST ]] ; then
-+ error "$(gettext "You do not have write permission to store profiles in %s.")" "$PROFDEST"
-+ plain "$(gettext "Aborting...")"
-+ exit 1
-+fi
-+
- LOGDEST=${_LOGDEST:-$LOGDEST}
- LOGDEST=${LOGDEST:-$startdir} #default to $startdir if undefined
- if (( LOGGING )) && [[ ! -w $LOGDEST ]]; then