b7afc0 build system: posix make support: refactored build-flavor dependency schemes.

Authored and Committed by midipix 3 years ago
    build system: posix make support: refactored build-flavor dependency schemes.
    
        
file modified
+8 -0
Makefile.in CHANGED
@@ -121,6 +121,14 @@ SHARED_LIB_LDFLAGS = @shared_lib_ldflags@
121
121
122
122
VERSION_OPT = @version_opt@
123
123
124
+ SHARED_LIBRARY_OPT = @shared_library_opt@
125
+ STATIC_LIBRARY_OPT = @static_library_opt@
126
+
127
+ APP_FRONTEND_OPT = @app_frontend_opt@
128
+ APP_LINKING_OPT = @app_linking_opt@
129
+
130
+ INSTALL_HEADERS_OPT = @install_headers_opt@
131
+
124
132
.cflags-host:
125
133
@printf '%s' "$(CFLAGS)"
126
134
file modified
+34 -0
configure CHANGED
@@ -657,6 +657,40 @@ config_opts()
657
657
else
658
658
mb_version_opt='used'
659
659
fi
660
+
661
+ if [ "$mb_custom_install_headers" = 'yes' ]; then
662
+ mb_install_headers_opt='custom'
663
+ else
664
+ mb_install_headers_opt='default'
665
+ fi
666
+
667
+ if [ "$mb_disable_static" = 'yes' ]; then
668
+ mb_static_library_opt='disabled'
669
+ else
670
+ mb_static_library_opt='enabled'
671
+ fi
672
+
673
+ if [ "$mb_disable_shared" = 'yes' ]; then
674
+ mb_shared_library_opt='disabled'
675
+ else
676
+ mb_shared_library_opt='enabled'
677
+ fi
678
+
679
+ if [ "$mb_disable_frontend" = 'yes' ]; then
680
+ mb_app_frontend_opt='disabled'
681
+ else
682
+ mb_app_frontend_opt='enabled'
683
+ fi
684
+
685
+ if [ "$mb_all_static" = 'yes' ]; then
686
+ mb_app_linking_opt='all_static'
687
+
688
+ elif [ "$mb_all_shared" = 'yes' ]; then
689
+ mb_app_linking_opt='all_shared'
690
+
691
+ else
692
+ mb_app_linking_opt='default'
693
+ fi
660
694
}
661
695
662
696
config_copy()
file modified
+8 -0
sofort/config/opt.vars CHANGED
@@ -1 +1,9 @@
1
1
version_opt
2
+
3
+ shared_library_opt
4
+ static_library_opt
5
+
6
+ app_frontend_opt
7
+ app_linking_opt
8
+
9
+ install_headers_opt
sofort/core/_flavor/flavor_app_frontend_disabled.mk ADDED
@@ -0,0 +1,6 @@
1
+ # flavor_app_frontend_disabled.mk: handling of frontend build options.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ app-tag:
5
+ package-install-app:
6
+ package-install-extras:
sofort/core/_flavor/flavor_app_frontend_enabled.mk ADDED
@@ -0,0 +1,6 @@
1
+ # flavor_app_frontend_enabled.mk: handling of frontend build options.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ app-tag: package-app app.tag
5
+ package-install-app: install-app
6
+ package-install-extras: install-extras
sofort/core/_flavor/flavor_app_linking_all_shared.mk ADDED
@@ -0,0 +1,7 @@
1
+ # flavor_app_linking_all_shared.mk: handling of frontend linking options.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ package-app: shared-app
5
+ app: PACKAGE_APP = $(SHARED_APP)
6
+ app-tag: PACKAGE_APP = $(SHARED_APP)
7
+ app.tag: $(SHARED_APP)
sofort/core/_flavor/flavor_app_linking_all_static.mk ADDED
@@ -0,0 +1,7 @@
1
+ # flavor_app_linking_all_static.mk: handling of frontend linking options.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ package-app: static-app
5
+ app: PACKAGE_APP = $(STATIC_APP)
6
+ app-tag: PACKAGE_APP = $(STATIC_APP)
7
+ app.tag: $(STATIC_APP)
sofort/core/_flavor/flavor_app_linking_default.mk ADDED
@@ -0,0 +1,7 @@
1
+ # flavor_app_linking_default.mk: handling of frontend linking options.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ package-app: default-app
5
+ app: PACKAGE_APP = $(DEFAULT_APP)
6
+ app-tag: PACKAGE_APP = $(DEFAULT_APP)
7
+ app.tag: $(DEFAULT_APP)
sofort/core/_flavor/flavor_install_headers_custom.mk ADDED
@@ -0,0 +1,4 @@
1
+ # flavor_install_headers_custom.mk: handling of header installation option.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ install-headers:install-headers-custom
sofort/core/_flavor/flavor_install_headers_default.mk ADDED
@@ -0,0 +1,4 @@
1
+ # flavor_install_headers_default.mk: handling of header installation option.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ install-headers:install-headers-default
sofort/core/_flavor/flavor_shared_library_disabled.mk ADDED
@@ -0,0 +1,5 @@
1
+ # flavor_shared_library_disabled.mk: handling of shared library dependencies.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ package-shared:
5
+ package-install-shared:
sofort/core/_flavor/flavor_shared_library_enabled.mk ADDED
@@ -0,0 +1,5 @@
1
+ # flavor_shared_library_enabled.mk: handling of shared library dependencies.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ package-shared: shared
5
+ package-install-shared: install-shared
sofort/core/_flavor/flavor_static_library_disabled.mk ADDED
@@ -0,0 +1,5 @@
1
+ # flavor_static_library_disabled.mk: handling of static library dependencies.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ package-static:
5
+ package-install-static:
sofort/core/_flavor/flavor_static_library_enabled.mk ADDED
@@ -0,0 +1,5 @@
1
+ # flavor_static_library_enabled.mk: handling of static library dependencies.
2
+ # this file is covered by COPYING.SOFORT.
3
+
4
+ package-static: static
5
+ package-install-static: install-static
file modified
+5 -64
sofort/core/flavor.mk CHANGED
@@ -3,69 +3,10 @@
3
3
4
4
include $(PROJECT_DIR)/sofort/exrules/$(OS_DSO_EXRULES).mk
5
5
6
- ifeq ($(DISABLE_STATIC),yes)
7
- package-static:
6
+ include $(PROJECT_DIR)/sofort/core/_flavor/flavor_static_library_$(STATIC_LIBRARY_OPT).mk
7
+ include $(PROJECT_DIR)/sofort/core/_flavor/flavor_shared_library_$(SHARED_LIBRARY_OPT).mk
8
- package-install-static:
9
- else
10
- package-static: static
11
- package-install-static: install-static
12
- endif
13
8
14
- ifeq ($(DISABLE_SHARED),yes)
15
- package-shared:
9
+ include $(PROJECT_DIR)/sofort/core/_flavor/flavor_app_frontend_$(APP_FRONTEND_OPT).mk
10
+ include $(PROJECT_DIR)/sofort/core/_flavor/flavor_app_linking_$(APP_LINKING_OPT).mk
16
- package-install-shared:
17
- else
18
- package-shared: shared
19
- package-install-shared: install-shared
20
- endif
21
11
22
-
12
+ include $(PROJECT_DIR)/sofort/core/_flavor/flavor_install_headers_$(INSTALL_HEADERS_OPT).mk
23
-
24
- ifeq ($(DISABLE_FRONTEND),yes)
25
- app-tag:
26
- package-install-app:
27
- package-install-extras:
28
- else
29
- app-tag: package-app app.tag
30
- package-install-app: install-app
31
- package-install-extras: install-extras
32
- endif
33
-
34
-
35
-
36
- ifeq ($(ALL_STATIC),yes)
37
-
38
- package-app: static-app
39
- app: PACKAGE_APP = $(STATIC_APP)
40
- app-tag: PACKAGE_APP = $(STATIC_APP)
41
- app.tag: $(STATIC_APP)
42
-
43
-
44
- else ifeq ($(ALL_SHARED),yes)
45
-
46
- package-app: shared-app
47
- app: PACKAGE_APP = $(SHARED_APP)
48
- app-tag: PACKAGE_APP = $(SHARED_APP)
49
- app.tag: $(SHARED_APP)
50
-
51
-
52
- else
53
-
54
- package-app: default-app
55
- app: PACKAGE_APP = $(DEFAULT_APP)
56
- app-tag: PACKAGE_APP = $(DEFAULT_APP)
57
- app.tag: $(DEFAULT_APP)
58
-
59
- endif
60
-
61
-
62
-
63
- ifeq ($(CUSTOM_INSTALL_HEADERS),yes)
64
-
65
- install-headers:install-headers-custom
66
-
67
- else
68
-
69
- install-headers:install-headers-default
70
-
71
- endif