Add some more in-line documentation for various Makefiles ENGINE-228
authorDamiano Boppart <damiano@pep-security.net>
Thu, 17 Aug 2017 13:18:19 +0000
branchENGINE-228
changeset 1968e30b1515b7b9
parent 1967 027b3e3febae
child 1969 ba5eb0aa23a4
Add some more in-line documentation for various Makefiles
Makefile
Makefile.conf
asn.1/Makefile
build-config/common.conf
src/Makefile
     1.1 --- a/Makefile	Wed Aug 16 15:37:02 2017 +0000
     1.2 +++ b/Makefile	Thu Aug 17 13:18:19 2017 +0000
     1.3 @@ -7,6 +7,7 @@
     1.4  
     1.5  include Makefile.conf
     1.6  
     1.7 +# YML_PATH is needed in the environment of every call to a program of the YML2 distribution
     1.8  export YML_PATH=$(YML2_PATH)
     1.9  
    1.10  .PHONY: all
     2.1 --- a/Makefile.conf	Wed Aug 16 15:37:02 2017 +0000
     2.2 +++ b/Makefile.conf	Thu Aug 17 13:18:19 2017 +0000
     2.3 @@ -3,7 +3,9 @@
     2.4  # This file may be used under the terms of the GNU General Public License version 3
     2.5  # see LICENSE.txt
     2.6  
     2.7 -# To use custom build configuration variables, put them in a new file at `build-config/<name>.conf`. Execute `export PLATFORM_OVERRIDE=<name>` before running make. If this environment variable is not set, make will load a default configuration for your platform.
     2.8 +# This file assembles all the make variables that a maintainer or dev may want to taylor to his or her needs on a given platform.
     2.9 +
    2.10 +# To use custom build configuration variables, put them in a new file with the path `build-config/<name>.conf`. Execute `export PLATFORM_OVERRIDE=<name>` before running make. If this environment variable is not set, make will load a default configuration for your platform.
    2.11  
    2.12  BUILD_CONFIG:=$(dir $(lastword $(MAKEFILE_LIST)))build-config
    2.13  
     3.1 --- a/asn.1/Makefile	Wed Aug 16 15:37:02 2017 +0000
     3.2 +++ b/asn.1/Makefile	Thu Aug 17 13:18:19 2017 +0000
     3.3 @@ -11,13 +11,13 @@
     3.4  libasn1.a: $(ALL_OBJECTS)
     3.5  	ar -rc $@ $^
     3.6  
     3.7 -# "converter-sample.c" is the example file containing a "main()" function generated by ans1c.
     3.8  .PHONY: generate
     3.9  generate: Sync-Protocols.c
    3.10 +	# "converter-sample.c" is the example file containing a "main()" function generated by ans1c.
    3.11  	rm -f converter-sample.c
    3.12  
    3.13 -# '-Wno-cpp' is required to suppress the warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" otherwise printed during the compilation of every asn1c-generated C file.
    3.14  %.o: %.c %.h
    3.15 +	# '-Wno-cpp' is required to suppress the warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" otherwise printed during the compilation of every asn1c-generated C file.
    3.16  	$(CC) $(CFLAGS) -Wno-cpp -I. $(ASN1C_INC) -c $< -o $@
    3.17  
    3.18  Sync-Protocols.c: pEp.asn1 devicegroup.asn1 protocols.asn1
     4.1 --- a/build-config/common.conf	Wed Aug 16 15:37:02 2017 +0000
     4.2 +++ b/build-config/common.conf	Thu Aug 17 13:18:19 2017 +0000
     4.3 @@ -3,6 +3,8 @@
     4.4  # This file may be used under the terms of the GNU General Public License version 3
     4.5  # see LICENSE.txt
     4.6  
     4.7 +# General remark: to use (only) system libraries, set all the *_INC and *_LIB variables to the empty string.
     4.8 +
     4.9  ######### General #########
    4.10  BUILD_ON:=$(shell uname)
    4.11  BUILD_FOR=$(BUILD_ON)
    4.12 @@ -24,12 +26,11 @@
    4.13  
    4.14  ######### C++ #########
    4.15  #CXX This option is platform-specific
    4.16 -# CXXFLAGS is used for the tests only
    4.17  #CXXFLAGS This option is platform-specific
    4.18  
    4.19  ######### C and C++ #########
    4.20  TARGET_ARCH=
    4.21 -# The following two variables will be appended to, you can thus not set them here to fixed value.
    4.22 +# The following two variables will be appended to. You can thus not set them to a fixed value here.
    4.23  LDFLAGS=
    4.24  LDLIBS=
    4.25  
    4.26 @@ -79,9 +80,9 @@
    4.27  # DEFAULT_KEYSERVER - string with default keyserver
    4.28  # CRASHDUMP_DEFAULT_LINES - number of log lines to deliver for crashdumps
    4.29  # Example:
    4.30 -#    EXTRA_MACROS= -DDEFAULT_KEYSERVER=\"default-server.org\" -DCRASHDUMP_DEFAULT_LINES=23
    4.31 +#    EXTRA_MACROS=-DDEFAULT_KEYSERVER=\"default-server.org\" -DCRASHDUMP_DEFAULT_LINES=23
    4.32  EXTRA_MACROS=
    4.33  
    4.34  ######### Misc #########
    4.35 -# Maybe include these variables here. Check how they are used throughout the project before setting them here
    4.36 +# FIXME Maybe include these variables here. Check how they are used throughout the project before setting them here
    4.37  #LLDB_BIN
     5.1 --- a/src/Makefile	Wed Aug 16 15:37:02 2017 +0000
     5.2 +++ b/src/Makefile	Thu Aug 17 13:18:19 2017 +0000
     5.3 @@ -32,8 +32,8 @@
     5.4  ifeq ($(OPENPGP),GPG)
     5.5      NO_SOURCE=pgp_netpgp.c
     5.6      CFLAGS+= -DUSE_GPG $(GPGME_INC) -DLIBGPGME=\"$(LIBGPGME)\"
     5.7 -    # FIXME Why was -lgpgme commented out?
     5.8      LDFLAGS+= $(GPGME_LIB)
     5.9 +    # No extra LDLIBS are needed here, because GPGME is dynamically loaded
    5.10  else ifeq ($(OPENPGP),NETPGP)
    5.11      NO_SOURCE=pgp_gpg.c
    5.12      CFLAGS+= -DUSE_NETPGP $(NETGPG_INC)
    5.13 @@ -58,13 +58,11 @@
    5.14  	sed 's,\($*\)\.o[ :]*,\1.o $@ : ,g' < $@.$$$$ > $@; \
    5.15  	rm -f $@.$$$$
    5.16  
    5.17 -# If only the goal 'clean' is given, do not include the generated 'X.d' files.
    5.18 +# If only the goal 'clean' is given, do not generate and include the '%.d' files.
    5.19  ifneq ($(MAKECMDGOALS),clean)
    5.20      -include $(DEPENDS)
    5.21  endif
    5.22  
    5.23 -
    5.24 -
    5.25  $(TARGET): libpEpEngine.a
    5.26  	$(CC) $(ALL_OBJECTS) $(LDFLAGS) $(LDLIBS) -o $@
    5.27