]> git.xonotic.org Git - xonotic/netradiant.git/blobdiff - easy-builder
radiant/build menu: reword Commandline as Command line
[xonotic/netradiant.git] / easy-builder
index 82c08d90836a84dc99d4b832d77f780d554bceff..fb7cabc83bbeec7fab0089b8bfd6d0412bc80d09 100755 (executable)
@@ -25,9 +25,13 @@ _nproc () {
                        'Linux')
                                egrep "^processor" /proc/cpuinfo | wc -l
                                ;;
-                       'FreeBSD'|'Darwin')
+                       'FreeBSD')
                                sysctl -n hw.ncpu
                                ;;
+                       'Darwin')
+                               sysctl -n hw.logicalcpu \
+                               || sysctl -n hw.ncpu
+                               ;;
                        'MSYS_NT-'*|'CYGWIN_NT-'*|'MINGW'*'_NT-'*)
                                if command -v 'wmic' >/dev/null
                                then
@@ -77,6 +81,12 @@ do
        fi
 done
 
+case "$(uname -s)" in
+       'Darwin')
+               cmake_user_opts[${#cmake_user_opts[@]}]='-DBUILTIN_GTKGLEXT=ON -DBUILTIN_GTKTHEME_MOJAVE=ON'
+               ;;
+esac
+
 set -x
 
 "${fetch_submodules_cmd[@]}"
@@ -91,6 +101,12 @@ cmake \
        "${cmake_user_opts[@]}" \
        "${project_source_dir}"
 
+cmake \
+       --build "${build_dir}" \
+       -- \
+       -j"${job_count}" \
+       'builtins'
+
 cmake \
        --build "${build_dir}" \
        -- \