Mon, 09 Sep 2013 10:48:08 +0200
further improved build system (debug is now a target instead of a configuration)
Makefile | file | annotate | diff | comparison | revisions | |
README | file | annotate | diff | comparison | revisions | |
clang-debug.mk | file | annotate | diff | comparison | revisions | |
clang.mk | file | annotate | diff | comparison | revisions | |
g++-debug.mk | file | annotate | diff | comparison | revisions | |
g++.mk | file | annotate | diff | comparison | revisions | |
gcc-debug.mk | file | annotate | diff | comparison | revisions | |
gcc.mk | file | annotate | diff | comparison | revisions | |
osx-debug.mk | file | annotate | diff | comparison | revisions | |
osx.mk | file | annotate | diff | comparison | revisions | |
suncc-debug.mk | file | annotate | diff | comparison | revisions | |
suncc.mk | file | annotate | diff | comparison | revisions | |
test/Makefile | file | annotate | diff | comparison | revisions | |
ucx/Makefile | file | annotate | diff | comparison | revisions | |
unix.mk | file | annotate | diff | comparison | revisions | |
windows.mk | file | annotate | diff | comparison | revisions |
1.1 --- a/Makefile Fri Sep 06 17:01:53 2013 +0200 1.2 +++ b/Makefile Mon Sep 09 10:48:08 2013 +0200 1.3 @@ -29,33 +29,43 @@ 1.4 1.5 # 1.6 # available configurations: 1.7 -# clang, clang-debug 1.8 -# gcc, gcc-debug 1.9 -# g++, g++-debug 1.10 -# osx, osx-debug 1.11 -# suncc, suncc-debug 1.12 +# clang 1.13 +# gcc 1.14 +# g++ 1.15 +# osx 1.16 +# suncc 1.17 # windows 1.18 # 1.19 1.20 CONF=gcc 1.21 PREFIX=/usr/local 1.22 1.23 -include unix.mk 1.24 include $(CONF).mk 1.25 1.26 all: ucx test 1.27 1.28 ucx: FORCE 1.29 - cd ucx; $(MAKE) CONF=$(CONF) all 1.30 + cd ucx; $(MAKE) CONF=$(CONF) 1.31 + 1.32 +ucx-debug: FORCE 1.33 + cd ucx; $(MAKE) CONF=$(CONF) debug 1.34 1.35 test: FORCE ucx 1.36 - cd test; $(MAKE) CONF=$(CONF) all 1.37 + cd test; $(MAKE) CONF=$(CONF) 1.38 + 1.39 +test-debug: FORCE ucx-debug 1.40 + cd test; $(MAKE) CONF=$(CONF) debug 1.41 1.42 run: FORCE test 1.43 - ./build/test$(APP_EXT) 1.44 + ./build/release/test/ucxtest$(APP_EXT) 1.45 + 1.46 +run-debug: FORCE test-debug 1.47 + ./build/debug/test/ucxtest$(APP_EXT) 1.48 + 1.49 +debug: ucx-debug test-debug 1.50 1.51 install: ucx $(PREFIX)/lib $(PREFIX)/include/ucx 1.52 - cp ./build/libucx$(LIB_EXT) $(PREFIX)/lib && \ 1.53 + cp ./build/release/libucx$(LIB_EXT) $(PREFIX)/lib && \ 1.54 cp ./ucx/*.h $(PREFIX)/include/ucx 1.55 1.56 uninstall:
2.1 --- a/README Fri Sep 06 17:01:53 2013 +0200 2.2 +++ b/README Mon Sep 09 10:48:08 2013 +0200 2.3 @@ -5,10 +5,11 @@ 2.4 2.5 0. Table of Contents: 2.6 2.7 - 1. Introduction ........................................................ 14 2.8 - 2. Build and Installation .............................................. 24 2.9 - 3. Documentation ....................................................... 57 2.10 - 4. Contact ............................................................. 65 2.11 + 1. Introduction ........................................................ 15 2.12 + 2. Build ............................................................... 25 2.13 + 3. Install ............................................................. 58 2.14 + 4. Documentation ....................................................... 70 2.15 + 5. Contact ............................................................. 78 2.16 2.17 2.18 1. Introduction 2.19 @@ -16,30 +17,47 @@ 2.20 UAP Common eXtensions provide useful data structures and algorithms for common 2.21 programmatic tasks in C language. By design the features are divided into 2.22 modules to minimize the library footprint. Using the build files you can create 2.23 -a static lib containing all modules, but you might also want use the UCX sources 2.24 -in your project and compile against specific modules to further minimize the 2.25 -footprint. Feel free to do so. 2.26 +a static and a shared lib containing all modules, but you might also want use 2.27 +the UCX sources in your project and compile specific modules to further minimize 2.28 +the footprint. Feel free to do so. 2.29 2.30 2.31 -2. Build and Installation 2.32 +2. Build 2.33 2.34 Untar the source archive and run 2.35 2.36 make CONF=<yourconfig> 2.37 2.38 -If you are using gcc, then simply run 2.39 +If you are going to use gcc, then simply run 2.40 2.41 make 2.42 2.43 -The available configurations are clang, clang-debug, gcc, gcc-debug, g++, 2.44 -g++-debug, osx, osx-debug, suncc, suncc-debug and windows. The later uses 2.45 -microsoft visual C++ compiler. If you want to use mingw oder cygwin, you can 2.46 -use the default gcc configuration. 2.47 +The available configurations are clang, gcc, g++, osx, suncc and windows. The 2.48 +later uses microsoft visual C++ compiler. If you want to use mingw oder cygwin, 2.49 +you can use the default gcc configuration. 2.50 2.51 The build files are placed into a build subdirectory, which is created if it 2.52 does not exists. 2.53 2.54 -To install UCX, run 2.55 +The default target builds an optimized binaries. Use the debug target by running 2.56 + 2.57 + make debug CONF=<yourconfig> 2.58 + 2.59 +to disable optimization and enable debug symbols. 2.60 + 2.61 +If you want to test your build either run 2.62 + 2.63 + make run CONF=<yourconfig> 2.64 + 2.65 +or 2.66 + 2.67 + make run-debug CONF=<yourconfig> 2.68 + 2.69 +Again, you can omit the CONF parameter, when using the gcc. 2.70 + 2.71 +3. Install 2.72 + 2.73 +Build the binaries as described in chapter two. Then install UCX, by running 2.74 2.75 make install 2.76 2.77 @@ -49,12 +67,7 @@ 2.78 2.79 The default prefix is /usr/local. 2.80 2.81 -If you want to test your build, run 2.82 - 2.83 - make run CONF=<yourconfig> 2.84 - 2.85 - 2.86 -3. Documentation 2.87 +4. Documentation 2.88 2.89 The code uses doxygen source code documentation. A html version of the 2.90 documentation is also available here: 2.91 @@ -62,7 +75,7 @@ 2.92 http://develop.uap-core.de/ucx/1.0/index.html 2.93 2.94 2.95 -4. Contact 2.96 +5. Contact 2.97 2.98 Copyright (c) 2013 Olaf Wintermann 2.99
3.1 --- a/clang-debug.mk Fri Sep 06 17:01:53 2013 +0200 3.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 3.3 @@ -1,34 +0,0 @@ 3.4 -# 3.5 -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 3.6 -# 3.7 -# Copyright 2013 Olaf Wintermann. All rights reserved. 3.8 -# 3.9 -# Redistribution and use in source and binary forms, with or without 3.10 -# modification, are permitted provided that the following conditions are met: 3.11 -# 3.12 -# 1. Redistributions of source code must retain the above copyright 3.13 -# notice, this list of conditions and the following disclaimer. 3.14 -# 3.15 -# 2. Redistributions in binary form must reproduce the above copyright 3.16 -# notice, this list of conditions and the following disclaimer in the 3.17 -# documentation and/or other materials provided with the distribution. 3.18 -# 3.19 -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 3.20 -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 3.21 -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 3.22 -# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE 3.23 -# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 3.24 -# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 3.25 -# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 3.26 -# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 3.27 -# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 3.28 -# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 3.29 -# POSSIBILITY OF SUCH DAMAGE. 3.30 -# 3.31 - 3.32 -CC = clang 3.33 -LD = clang 3.34 - 3.35 -CFLAGS = -std=gnu99 -g -fstrict-aliasing -Wall -pedantic -c 3.36 -LDFLAGS = -lm 3.37 -
4.1 --- a/clang.mk Fri Sep 06 17:01:53 2013 +0200 4.2 +++ b/clang.mk Mon Sep 09 10:48:08 2013 +0200 4.3 @@ -26,9 +26,23 @@ 4.4 # POSSIBILITY OF SUCH DAMAGE. 4.5 # 4.6 4.7 -CC = clang 4.8 -LD = clang 4.9 +CC = clang 4.10 +LD = clang 4.11 +AR = ar 4.12 +RM = rm 4.13 +MKDIR = mkdir 4.14 4.15 -CFLAGS = -std=gnu99 -O2 -fstrict-aliasing -c 4.16 -LDFLAGS = -lm 4.17 +CFLAGS = -std=gnu99 -O2 -fstrict-aliasing -c 4.18 +CFLAGS_D = -std=gnu99 -g -fstrict-aliasing -Wall -pedantic -c 4.19 +COFLAGS = -o 4.20 +LDFLAGS = -lm 4.21 +LDFLAGS_D = -lm 4.22 +LOFLAGS = -o 4.23 +ARFLAGS = -r 4.24 +AOFLAGS = 4.25 +RMFLAGS = -f -R 4.26 +MKDIRFLAGS = -p 4.27 4.28 +OBJ_EXT = .o 4.29 +LIB_EXT = .a 4.30 +APP_EXT =
5.1 --- a/g++-debug.mk Fri Sep 06 17:01:53 2013 +0200 5.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 5.3 @@ -1,43 +0,0 @@ 5.4 -# 5.5 -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 5.6 -# 5.7 -# Copyright 2013 Olaf Wintermann. All rights reserved. 5.8 -# 5.9 -# Redistribution and use in source and binary forms, with or without 5.10 -# modification, are permitted provided that the following conditions are met: 5.11 -# 5.12 -# 1. Redistributions of source code must retain the above copyright 5.13 -# notice, this list of conditions and the following disclaimer. 5.14 -# 5.15 -# 2. Redistributions in binary form must reproduce the above copyright 5.16 -# notice, this list of conditions and the following disclaimer in the 5.17 -# documentation and/or other materials provided with the distribution. 5.18 -# 5.19 -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 5.20 -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 5.21 -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 5.22 -# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE 5.23 -# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 5.24 -# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 5.25 -# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 5.26 -# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 5.27 -# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 5.28 -# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 5.29 -# POSSIBILITY OF SUCH DAMAGE. 5.30 -# 5.31 - 5.32 -CC = g++ 5.33 -LD = g++ 5.34 -AR = ar 5.35 -RM = rm 5.36 - 5.37 -CFLAGS = -std=gnu++0x -g -fstrict-aliasing -Wall -pedantic -c 5.38 -COFLAGS = -o 5.39 -LDFLAGS = 5.40 -LOFLAGS = -o 5.41 -ARFLAGS = -r 5.42 -RMFLAGS = -f 5.43 - 5.44 -OBJ_EXT = o 5.45 -LIB_EXT = a 5.46 -APP_EXT =
6.1 --- a/g++.mk Fri Sep 06 17:01:53 2013 +0200 6.2 +++ b/g++.mk Mon Sep 09 10:48:08 2013 +0200 6.3 @@ -26,19 +26,23 @@ 6.4 # POSSIBILITY OF SUCH DAMAGE. 6.5 # 6.6 6.7 -CC = g++ 6.8 -LD = g++ 6.9 -AR = ar 6.10 -RM = rm 6.11 +CC = g++ 6.12 +LD = g++ 6.13 +AR = ar 6.14 +RM = rm 6.15 +MKDIR = mkdir 6.16 6.17 -CFLAGS = -std=gnu++0x -O2 -fstrict-aliasing -c 6.18 -COFLAGS = -o 6.19 -LDFLAGS = 6.20 -LOFLAGS = -o 6.21 -ARFLAGS = -r 6.22 -RMFLAGS = -f 6.23 +CFLAGS = -std=gnu++0x -O2 -fstrict-aliasing -c 6.24 +CFLAGS_D = -std=gnu++0x -g -fstrict-aliasing -Wall -pedantic -c 6.25 +COFLAGS = -o 6.26 +LDFLAGS = 6.27 +LDFLAGS_D = 6.28 +LOFLAGS = -o 6.29 +ARFLAGS = -r 6.30 +AOFLAGS = 6.31 +RMFLAGS = -f -R 6.32 +MKDIRFLAGS = -p 6.33 6.34 -OBJ_EXT = o 6.35 -LIB_EXT = a 6.36 +OBJ_EXT = .o 6.37 +LIB_EXT = .a 6.38 APP_EXT = 6.39 -
7.1 --- a/gcc-debug.mk Fri Sep 06 17:01:53 2013 +0200 7.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 7.3 @@ -1,34 +0,0 @@ 7.4 -# 7.5 -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 7.6 -# 7.7 -# Copyright 2013 Olaf Wintermann. All rights reserved. 7.8 -# 7.9 -# Redistribution and use in source and binary forms, with or without 7.10 -# modification, are permitted provided that the following conditions are met: 7.11 -# 7.12 -# 1. Redistributions of source code must retain the above copyright 7.13 -# notice, this list of conditions and the following disclaimer. 7.14 -# 7.15 -# 2. Redistributions in binary form must reproduce the above copyright 7.16 -# notice, this list of conditions and the following disclaimer in the 7.17 -# documentation and/or other materials provided with the distribution. 7.18 -# 7.19 -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 7.20 -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 7.21 -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 7.22 -# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE 7.23 -# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 7.24 -# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 7.25 -# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 7.26 -# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 7.27 -# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 7.28 -# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 7.29 -# POSSIBILITY OF SUCH DAMAGE. 7.30 -# 7.31 - 7.32 -CC = gcc 7.33 -LD = gcc 7.34 - 7.35 -CFLAGS = -std=gnu99 -g -fstrict-aliasing -Wall -pedantic -c 7.36 -LDFLAGS = 7.37 -
8.1 --- a/gcc.mk Fri Sep 06 17:01:53 2013 +0200 8.2 +++ b/gcc.mk Mon Sep 09 10:48:08 2013 +0200 8.3 @@ -26,9 +26,23 @@ 8.4 # POSSIBILITY OF SUCH DAMAGE. 8.5 # 8.6 8.7 -CC = gcc 8.8 -LD = gcc 8.9 +CC = gcc 8.10 +LD = gcc 8.11 +AR = ar 8.12 +RM = rm 8.13 +MKDIR = mkdir 8.14 8.15 -CFLAGS = -std=gnu99 -O2 -fstrict-aliasing -c 8.16 -LDFLAGS = 8.17 +CFLAGS = -std=gnu99 -O2 -fstrict-aliasing -c 8.18 +CFLAGS_D = -std=gnu99 -g -fstrict-aliasing -Wall -pedantic -c 8.19 +COFLAGS = -o 8.20 +LDFLAGS = 8.21 +LDFLAGS_D = 8.22 +LOFLAGS = -o 8.23 +ARFLAGS = -r 8.24 +AOFLAGS = 8.25 +RMFLAGS = -f -R 8.26 +MKDIRFLAGS = -p 8.27 8.28 +OBJ_EXT = .o 8.29 +LIB_EXT = .a 8.30 +APP_EXT =
9.1 --- a/osx-debug.mk Fri Sep 06 17:01:53 2013 +0200 9.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 9.3 @@ -1,34 +0,0 @@ 9.4 -# 9.5 -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 9.6 -# 9.7 -# Copyright 2013 Olaf Wintermann. All rights reserved. 9.8 -# 9.9 -# Redistribution and use in source and binary forms, with or without 9.10 -# modification, are permitted provided that the following conditions are met: 9.11 -# 9.12 -# 1. Redistributions of source code must retain the above copyright 9.13 -# notice, this list of conditions and the following disclaimer. 9.14 -# 9.15 -# 2. Redistributions in binary form must reproduce the above copyright 9.16 -# notice, this list of conditions and the following disclaimer in the 9.17 -# documentation and/or other materials provided with the distribution. 9.18 -# 9.19 -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 9.20 -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 9.21 -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 9.22 -# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE 9.23 -# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 9.24 -# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 9.25 -# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 9.26 -# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 9.27 -# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 9.28 -# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 9.29 -# POSSIBILITY OF SUCH DAMAGE. 9.30 -# 9.31 - 9.32 -CC = cc 9.33 -LD = cc 9.34 - 9.35 -CFLAGS = -g -c 9.36 -LDFLAGS = 9.37 -
10.1 --- a/osx.mk Fri Sep 06 17:01:53 2013 +0200 10.2 +++ b/osx.mk Mon Sep 09 10:48:08 2013 +0200 10.3 @@ -26,9 +26,23 @@ 10.4 # POSSIBILITY OF SUCH DAMAGE. 10.5 # 10.6 10.7 -CC = cc 10.8 -LD = cc 10.9 +CC = cc 10.10 +LD = cc 10.11 +AR = ar 10.12 +RM = rm 10.13 +MKDIR = mkdir 10.14 10.15 -CFLAGS = -O2 -c 10.16 -LDFLAGS = 10.17 +CFLAGS = -O2 -c 10.18 +CFLAGS_D = -g -c 10.19 +COFLAGS = -o 10.20 +LDFLAGS = 10.21 +LDFLAGS_D = 10.22 +LOFLAGS = -o 10.23 +ARFLAGS = -r 10.24 +AOFLAGS = 10.25 +RMFLAGS = -f -R 10.26 +MKDIRFLAGS = -p 10.27 10.28 +OBJ_EXT = .o 10.29 +LIB_EXT = .a 10.30 +APP_EXT =
11.1 --- a/suncc-debug.mk Fri Sep 06 17:01:53 2013 +0200 11.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 11.3 @@ -1,34 +0,0 @@ 11.4 -# 11.5 -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 11.6 -# 11.7 -# Copyright 2013 Olaf Wintermann. All rights reserved. 11.8 -# 11.9 -# Redistribution and use in source and binary forms, with or without 11.10 -# modification, are permitted provided that the following conditions are met: 11.11 -# 11.12 -# 1. Redistributions of source code must retain the above copyright 11.13 -# notice, this list of conditions and the following disclaimer. 11.14 -# 11.15 -# 2. Redistributions in binary form must reproduce the above copyright 11.16 -# notice, this list of conditions and the following disclaimer in the 11.17 -# documentation and/or other materials provided with the distribution. 11.18 -# 11.19 -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 11.20 -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 11.21 -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 11.22 -# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE 11.23 -# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 11.24 -# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 11.25 -# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 11.26 -# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 11.27 -# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 11.28 -# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 11.29 -# POSSIBILITY OF SUCH DAMAGE. 11.30 -# 11.31 - 11.32 -CC = cc 11.33 -LD = cc 11.34 - 11.35 -CFLAGS = -g -c 11.36 -LDFLAGS = -lm 11.37 -
12.1 --- a/suncc.mk Fri Sep 06 17:01:53 2013 +0200 12.2 +++ b/suncc.mk Mon Sep 09 10:48:08 2013 +0200 12.3 @@ -26,9 +26,23 @@ 12.4 # POSSIBILITY OF SUCH DAMAGE. 12.5 # 12.6 12.7 -CC = cc 12.8 -LD = cc 12.9 +CC = cc 12.10 +LD = cc 12.11 +AR = ar 12.12 +RM = rm 12.13 +MKDIR = mkdir 12.14 12.15 -CFLAGS = -O -c 12.16 -LDFLAGS = -lm 12.17 +CFLAGS = -O -c 12.18 +CFLAGS_D = -g -c 12.19 +COFLAGS = -o 12.20 +LDFLAGS = -lm 12.21 +LDFLAGS_D = -lm 12.22 +LOFLAGS = -o 12.23 +ARFLAGS = -r 12.24 +AOFLAGS = 12.25 +RMFLAGS = -f -R 12.26 +MKDIRFLAGS = -p 12.27 12.28 +OBJ_EXT = .o 12.29 +LIB_EXT = .a 12.30 +APP_EXT =
13.1 --- a/test/Makefile Fri Sep 06 17:01:53 2013 +0200 13.2 +++ b/test/Makefile Mon Sep 09 10:48:08 2013 +0200 13.3 @@ -26,7 +26,6 @@ 13.4 # POSSIBILITY OF SUCH DAMAGE. 13.5 # 13.6 13.7 -include ../unix.mk 13.8 include ../$(CONF).mk 13.9 13.10 SRC = main.c 13.11 @@ -39,16 +38,28 @@ 13.12 SRC += buffer_tests.c 13.13 SRC += utils_tests.c 13.14 13.15 -OBJ = $(SRC:%.c=../build/%$(OBJ_EXT)) 13.16 +OBJ = $(SRC:%.c=../build/release/test/%$(OBJ_EXT)) 13.17 +OBJ_D = $(SRC:%.c=../build/debug/test/%$(OBJ_EXT)) 13.18 13.19 -all: ../build/ ../build/test 13.20 +all: ../build/release/test ../build/release/test/ucxtest$(APP_EXT) 13.21 +debug: ../build/debug/test ../build/debug/test/ucxtest$(APP_EXT) 13.22 13.23 -../build/test: $(OBJ) 13.24 - $(LD) $(LDFLAGS) $(LOFLAGS)../build/test$(APP_EXT) $(OBJ) \ 13.25 - ../build/libucx$(LIB_EXT) 13.26 +../build/release/test/ucxtest$(APP_EXT): $(OBJ) 13.27 + $(LD) $(LDFLAGS) $(LOFLAGS)../build/release/test/ucxtest$(APP_EXT) \ 13.28 + $(OBJ) ../build/release/libucx$(LIB_EXT) 13.29 13.30 -../build/%$(OBJ_EXT): %.c 13.31 +../build/release/test/%$(OBJ_EXT): %.c 13.32 $(CC) $(CFLAGS) -I../ $(COFLAGS)$@ $< 13.33 13.34 -../build: 13.35 - $(MKDIR) $(MKDIRFLAGS) ../build/test 13.36 +../build/release/test: 13.37 + $(MKDIR) $(MKDIRFLAGS) ../build/release/test 13.38 + 13.39 +../build/debug/test/ucxtest$(APP_EXT): $(OBJ_D) 13.40 + $(LD) $(LDFLAGS_D) $(LOFLAGS)../build/debug/test/ucxtest$(APP_EXT) \ 13.41 + $(OBJ_D) ../build/debug/libucx$(LIB_EXT) 13.42 + 13.43 +../build/debug/test/%$(OBJ_EXT): %.c 13.44 + $(CC) $(CFLAGS_D) -I../ $(COFLAGS)$@ $< 13.45 + 13.46 +../build/debug/test: 13.47 + $(MKDIR) $(MKDIRFLAGS) ../build/debug/test
14.1 --- a/ucx/Makefile Fri Sep 06 17:01:53 2013 +0200 14.2 +++ b/ucx/Makefile Mon Sep 09 10:48:08 2013 +0200 14.3 @@ -26,7 +26,6 @@ 14.4 # POSSIBILITY OF SUCH DAMAGE. 14.5 # 14.6 14.7 -include ../unix.mk 14.8 include ../$(CONF).mk 14.9 14.10 # list of source files 14.11 @@ -41,15 +40,26 @@ 14.12 SRC += logging.c 14.13 SRC += buffer.c 14.14 14.15 -OBJ = $(SRC:%.c=../build/ucx/%$(OBJ_EXT)) 14.16 +OBJ = $(SRC:%.c=../build/release/ucx/%$(OBJ_EXT)) 14.17 +OBJ_D = $(SRC:%.c=../build/debug/ucx/%$(OBJ_EXT)) 14.18 14.19 -all: ../build/ucx ../build/libucx$(LIB_EXT) 14.20 +all: ../build/release/ucx ../build/release/libucx$(LIB_EXT) 14.21 +debug: ../build/debug/ucx ../build/debug/libucx$(LIB_EXT) 14.22 14.23 -../build/libucx$(LIB_EXT): $(OBJ) 14.24 - $(AR) $(ARFLAGS) $(AOFLAGS)../build/libucx$(LIB_EXT) $(OBJ) 14.25 +../build/release/libucx$(LIB_EXT): $(OBJ) 14.26 + $(AR) $(ARFLAGS) $(AOFLAGS)../build/release/libucx$(LIB_EXT) $(OBJ) 14.27 14.28 -../build/ucx/%$(OBJ_EXT): %.c 14.29 +../build/release/ucx/%$(OBJ_EXT): %.c 14.30 $(CC) $(CFLAGS) $(COFLAGS)$@ $< 14.31 14.32 -../build/ucx: 14.33 - $(MKDIR) $(MKDIRFLAGS) ../build/ucx 14.34 +../build/release/ucx: 14.35 + $(MKDIR) $(MKDIRFLAGS) ../build/release/ucx 14.36 + 14.37 +../build/debug/libucx$(LIB_EXT): $(OBJ_D) 14.38 + $(AR) $(ARFLAGS) $(AOFLAGS)../build/debug/libucx$(LIB_EXT) $(OBJ_D) 14.39 + 14.40 +../build/debug/ucx/%$(OBJ_EXT): %.c 14.41 + $(CC) $(CFLAGS_D) $(COFLAGS)$@ $< 14.42 + 14.43 +../build/debug/ucx: 14.44 + $(MKDIR) $(MKDIRFLAGS) ../build/debug/ucx
15.1 --- a/unix.mk Fri Sep 06 17:01:53 2013 +0200 15.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 15.3 @@ -1,44 +0,0 @@ 15.4 -# 15.5 -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 15.6 -# 15.7 -# Copyright 2013 Olaf Wintermann. All rights reserved. 15.8 -# 15.9 -# Redistribution and use in source and binary forms, with or without 15.10 -# modification, are permitted provided that the following conditions are met: 15.11 -# 15.12 -# 1. Redistributions of source code must retain the above copyright 15.13 -# notice, this list of conditions and the following disclaimer. 15.14 -# 15.15 -# 2. Redistributions in binary form must reproduce the above copyright 15.16 -# notice, this list of conditions and the following disclaimer in the 15.17 -# documentation and/or other materials provided with the distribution. 15.18 -# 15.19 -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 15.20 -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 15.21 -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 15.22 -# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE 15.23 -# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 15.24 -# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 15.25 -# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 15.26 -# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 15.27 -# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 15.28 -# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 15.29 -# POSSIBILITY OF SUCH DAMAGE. 15.30 -# 15.31 - 15.32 -CC = @echo "\nInvalid configuration.\n" && /bin/false 15.33 -LD = @echo "\nInvalid configuration.\n" && /bin/false 15.34 -AR = ar 15.35 -RM = rm 15.36 -MKDIR = mkdir 15.37 - 15.38 -COFLAGS = -o ./ 15.39 -LOFLAGS = -o ./ 15.40 -ARFLAGS = -r 15.41 -RMFLAGS = -f -R 15.42 -MKDIRFLAGS = -p 15.43 - 15.44 -OBJ_EXT = .o 15.45 -LIB_EXT = .a 15.46 -APP_EXT = 15.47 -
16.1 --- a/windows.mk Fri Sep 06 17:01:53 2013 +0200 16.2 +++ b/windows.mk Mon Sep 09 10:48:08 2013 +0200 16.3 @@ -26,18 +26,23 @@ 16.4 # POSSIBILITY OF SUCH DAMAGE. 16.5 # 16.6 16.7 -CC = cl 16.8 -LD = link 16.9 -AR = lib 16.10 +CC = cl 16.11 +LD = link 16.12 +AR = lib 16.13 +RM = rm 16.14 +MKDIR = mkdir 16.15 16.16 -CFLAGS = -c -TP -I../msc 16.17 -COFLAGS = -Fo 16.18 -LDFLAGS = 16.19 -LOFLAGS = -OUT: 16.20 -ARFLAGS = 16.21 -AOFLAGS = -OUT: 16.22 +CFLAGS = -c -TP -I../msc 16.23 +CFLAGS_D = -c -TP -I../msc 16.24 +COFLAGS = -Fo 16.25 +LDFLAGS = 16.26 +LDFLAGS_D = 16.27 +LOFLAGS = -OUT: 16.28 +ARFLAGS = 16.29 +AOFLAGS = -OUT: 16.30 +RMFLAGS = -f -R 16.31 +MKDIRFLAGS = -p 16.32 16.33 OBJ_EXT = .obj 16.34 LIB_EXT = .lib 16.35 APP_EXT = .exe 16.36 -