]> Kevux Git Server - fll/commitdiff
Update: Restructure fake settings, moving examples into a new projects directory.
authorKevin Day <thekevinday@gmail.com>
Sun, 12 Dec 2021 15:41:16 +0000 (09:41 -0600)
committerKevin Day <thekevinday@gmail.com>
Sun, 12 Dec 2021 15:54:06 +0000 (09:54 -0600)
Create a projects directory to store some real replacements of other projects build systems.
The bzip2 build system was used as just an example and is now treated as a real use case.

I am planning on trying to use cmocka to provide unit tests for this project.
The cmocka uses that rather unpleasant cmake.
Provide a cmocka fake build setting file for building cmocka.

level_3/fake/data/build/fakefile-example-bzip2 [deleted file]
level_3/fake/data/build/fakefile-example-linux_using_make
level_3/fake/data/projects/bzip2/1.0.8/fakefile [new file with mode: 0644]
level_3/fake/data/projects/bzip2/1.0.8/settings-bzip2 [moved from level_3/fake/data/build/settings-example-bzip2 with 54% similarity]
level_3/fake/data/projects/bzip2/1.0.8/settings-bzip2recover [moved from level_3/fake/data/build/settings-example-bzip2recover with 72% similarity]
level_3/fake/data/projects/cmocka/1.1.5/settings [new file with mode: 0644]

diff --git a/level_3/fake/data/build/fakefile-example-bzip2 b/level_3/fake/data/build/fakefile-example-bzip2
deleted file mode 100644 (file)
index 35d51b1..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-# fss-0005 iki-0002
-#
-# This is designed for bzip2-1.0.8 as an example for compiling bzip2.
-#
-# To use this example do the following:
-#   1) download and extract bzip2-1.0.8.
-#   2) change into the extracted bzip2-1.0.8 directory.
-#   3) create the directory path "data/build/" within this bzip2-1.0.8 directory.
-#   4) copy the files fakefile-example-bzip2, settings-example-bzip2, and settings-example-bzip2recover) into the created directory path "data/build/".
-#   5) use the featureless make build operation to make, such as: "fake make -f fakefile-example-bzip2".
-
-settings:
-  load_build no
-  fail exit
-
-  compiler gcc
-  indexer ar
-  indexer_arguments rcs
-
-main:
-  operate bzip2
-  operate bzip2recover
-  operate scripts
-
-bzip2:
-  print
-  print Building settings-example-bzip2.
-  build settings-example-bzip2
-
-bzip2recover:
-  print
-  print Building settings-example-bzip2recover.
-  build settings-example-bzip2recover
-
-scripts:
-  print
-  print copying bzip2 scripts.
-  touch directory build build/programs build/programs/scripts
-  copy bzdiff bzgrep build/programs/scripts
index 1417a821111f27a39410c433834a76ae3842ff24..76ca62a91c4f8ef95f2718fed4cec835803f0311 100644 (file)
@@ -6,9 +6,9 @@
 # This assumes make and everything necessary to compile the linux kernel is available.
 #
 # To use this example do the following:
-#   1) download and extract the linux source, such as linux-5.8.8.
-#   2) change into the extracted source (linux-5.8.8) directory.
-#   3) run using this, such as: "fake make -f /path/to/fakefile-example-bzip2".
+#   1) Download and extract the linux source, such as linux-5.8.8.
+#   2) Change into the extracted source (linux-5.8.8) directory.
+#   3) Run using this, such as: "fake make -f /path/to/fakefile-example-linux_using_make".
 
 settings:
   load_build no
@@ -21,7 +21,6 @@ settings:
   parameter config defconfig
 
 main:
-
   print
   print Cleaning Linux kernel source.
   run make mrproper
diff --git a/level_3/fake/data/projects/bzip2/1.0.8/fakefile b/level_3/fake/data/projects/bzip2/1.0.8/fakefile
new file mode 100644 (file)
index 0000000..fd8104b
--- /dev/null
@@ -0,0 +1,39 @@
+# fss-0005 iki-0002
+#
+# This is designed for compiling bzip2-1.0.8.
+#
+# To use this do the following:
+#   1) Download and extract bzip2-1.0.8.
+#   2) Change into the extracted bzip2-1.0.8 directory.
+#   3) Create the directory path "data/build/" within this bzip2-1.0.8 directory.
+#   4) Copy the files fakefile-bzip2, settings-bzip2, and settings-bzip2recover) into the created directory path "data/build/".
+#   5) Use the featureless make build operation to make, such as: "fake make -f fakefile-bzip2".
+
+settings:
+  load_build no
+  fail exit
+
+  compiler gcc
+  indexer ar
+  indexer_arguments rcs
+
+main:
+  operate bzip2
+  operate bzip2recover
+  operate scripts
+
+bzip2:
+  print
+  print Building settings-bzip2.
+  build settings-bzip2
+
+bzip2recover:
+  print
+  print Building settings-bzip2recover.
+  build settings-bzip2recover
+
+scripts:
+  print
+  print copying bzip2 scripts.
+  touch directory build build/programs build/programs/scripts
+  copy bzdiff bzgrep build/programs/scripts
similarity index 54%
rename from level_3/fake/data/build/settings-example-bzip2
rename to level_3/fake/data/projects/bzip2/1.0.8/settings-bzip2
index 5af88ff1ba93852a3680a690ff96b1f6402df8d0..6373619eccf295b74b0c263b9f44f75600adb04c 100644 (file)
@@ -1,13 +1,13 @@
 # fss-0001
 #
-# This is designed for bzip2-1.0.8 as an example for compiling bzip2.
+# This is designed for compiling bzip2-1.0.8.
 #
-# To use this example do the following:
-#   1) download and extract bzip2-1.0.8.
-#   2) change into the extracted bzip2-1.0.8 directory.
-#   3) create the directory path "data/build/" within this bzip2-1.0.8 directory.
-#   4) copy this file (settings-example-bzip2) into the created directory path "data/build/".
-#   5) use the featureless make build operation to build, such as: "fake build -s settings-example-bzip2".
+# To use this do the following:
+#   1) Download and extract bzip2-1.0.8.
+#   2) Change into the extracted bzip2-1.0.8 directory.
+#   3) Create the directory path "data/build/" within this bzip2-1.0.8 directory.
+#   4) Copy this file (settings-bzip2) into the created directory path "data/build/".
+#   5) Use the featureless make build operation to build, such as: "fake build -s settings-bzip2".
 
 project_name bzip2
 
similarity index 72%
rename from level_3/fake/data/build/settings-example-bzip2recover
rename to level_3/fake/data/projects/bzip2/1.0.8/settings-bzip2recover
index da70061b43b2650b8e3b893494490231e732536e..515c373e7d6cb8589fe1cc27a94e820f3c7ad08d 100644 (file)
@@ -1,13 +1,13 @@
 # fss-0001
 #
-# This is designed for bzip2-1.0.8 as an example for compiling bzip2recover.
+# This is designed for compiling bzip2-1.0.8.
 #
-# To use this example do the following:
+# To use this do the following:
 #   1) download and extract bzip2-1.0.8.
 #   2) change into the extracted bzip2-1.0.8 directory.
 #   3) create the directory path "data/build/" within this bzip2-1.0.8 directory.
-#   4) copy this file (settings-example-bzip2recover) into the created directory path "data/build/".
-#   5) use the featureless make build operation to build, such as: "fake build -s settings-example-bzip2recover".
+#   4) copy this file (settings-bzip2recover) into the created directory path "data/build/".
+#   5) use the featureless make build operation to build, such as: "fake build -s settings-bzip2recover".
 
 project_name bzip2recover
 
diff --git a/level_3/fake/data/projects/cmocka/1.1.5/settings b/level_3/fake/data/projects/cmocka/1.1.5/settings
new file mode 100644 (file)
index 0000000..6a82626
--- /dev/null
@@ -0,0 +1,39 @@
+# fss-0001
+#
+# This is designed for compiling cmocka-1.1.5.
+#
+# To use this do the following:
+#   1) Download and extract cmocka-1.1.5.
+#   2) Change into the extracted cmocka-1.1.5 directory.
+#   3) Create the directory path "data/build/" within this cmocka-1.1.5 directory.
+#   4) Copy this file (settings) into the created directory path "data/build/".
+#   5) Use the featureless make build operation to build, such as: "fake build".
+#
+# This depends on a c-library with realtime and pthread support.
+
+project_name cmocka
+
+version_major 1
+version_minor 1
+version_micro 5
+version_file micro
+version_target major
+
+build_compiler gcc
+build_indexer ar
+build_indexer_arguments rcs
+build_language c
+build_libraries -pthread -lrt -lc
+build_sources_library src/cmocka.c
+build_sources_headers include/cmocka.h include/cmocka_pbc.h
+build_script no
+
+path_sources
+path_standard no
+
+defines -DHAVE_MALLOC_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_SIGNAL_H=1 -DHAVE_STRINGS_H=1 -DHAVE_GCC_THREAD_LOCAL_STORAGE=1 -DHAVE_CLOCK_REALTIME=1 -DHAVE_SIGLONGJMP=1 -DHAVE_STRSIGNAL=1
+
+flags -z now -g -fdiagnostics-color=always -Wall -Winline -O2 -Iinclude/ -std=gnu99
+flags -Wpedantic -Wall -Wshadow -Wmissing-prototypes -Wcast-align -Werror=address -Wstrict-prototypes -Werror=strict-prototypes -Wwrite-strings -Werror=write-strings -Werror-implicit-function-declaration -Wpointer-arith -Werror=pointer-arith -Wdeclaration-after-statement -Werror=declaration-after-statement -Wreturn-type -Werror=return-type -Wuninitialized -Werror=uninitialized -Wimplicit-fallthrough -Werror=strict-overflow -Wstrict-overflow=2 -Wno-format-zero-length -Wmissing-field-initializers -Wformat -Wformat-security -Werror=format-security
+flags -fno-common -fstack-protector-strong -fstack-clash-protection
+flags_library -fPIC