]> Kevux Git Server - fll/commitdiff
Update: The bootstrap example script now handles building using fake.
authorKevin Day <Kevin@kevux.org>
Tue, 1 Oct 2024 02:05:21 +0000 (21:05 -0500)
committerKevin Day <Kevin@kevux.org>
Tue, 1 Oct 2024 02:23:22 +0000 (21:23 -0500)
The bootstrap example script is generally for using bootstrap scripts.

I have ended up using this for regular building because it is simple and already written.
The FLL 0.7 development now has build settings for some programs that do not build using the bootstrap without additional parameters.

Add support for the bootstrap script to use `fake` directly if it exists in the PATH for these particular programs.

build/scripts/bootstrap-example.sh

index a8ff064ec5caa68326dcb38f02846b9976db1ce6..825ca505332e15c9ed5b36aad4eb2c899cf5c9ce 100644 (file)
@@ -69,6 +69,7 @@ build_mode_extra_param_2=
 build_mode_extra_value_2=
 shell_command=bash
 exclude_programs=
+fake_programs="fss_read fss_write status_code"
 grab_next=
 skip=
 
@@ -320,6 +321,22 @@ elif [[ ${1} == "programs-individual" || ${1} == "programs-level" || ${1} == "pr
       ${shell_command} ./install.sh ${verbose} ${color} ${shared} ${static} -w ${path_work} ||
 
       break
+
+      if [[ $(type -p fake) != "" && ${fake_programs} != "" ]] ; then
+        for j in ${fake_programs} ; do
+          if [[ ${i} == "${j}-${version}" ]] ; then
+            cd ${path_original}package/program/${i} &&
+
+            fake clean make ${verbose} ${color} ${shared} ${static} -w ${path_work} -m ${build_mode} ${build_mode_extra_param_1} ${build_mode_extra_value_1} ${build_mode_extra_param_2} ${build_mode_extra_value_2} ${mode_compiler_param} ${mode_compiler_value} &&
+
+            ${shell_command} ./install.sh ${verbose} ${color} ${shared} ${static} -w ${path_work} ||
+
+            skip="break"
+          fi
+        done
+
+       if [[ $skip == "break" ]] ; then break ; fi
+     fi
     done
   else
     echo