Cleaned up Makefile

This commit is contained in:
John Jones 2016-11-14 08:11:21 -05:00
parent f57e928cf8
commit 4c3c2a59ed
4 changed files with 11 additions and 4 deletions

1
.gitignore vendored
View file

@ -5,6 +5,7 @@
!**/
*.o
*.a
.cproject
.project
.settings/language.settings.xml

View file

@ -1,6 +1,8 @@
DEBUG=true
CC = gcc
RM = rm -f
CFLAGS = -fPIC -g -O2 -std=c99 \
CFLAGS = -fPIC -O0 -std=c99 \
-Wall -Wextra -pedantic -Werror \
-Wdeclaration-after-statement \
-Wno-format-zero-length \
@ -10,10 +12,14 @@ CFLAGS = -fPIC -g -O2 -std=c99 \
-Wunused \
-Wvla
ifdef DEBUG
CFLAGS += -g3
endif
LDFLAGS = -g
LDLIBS =
TARGET_LIB = mulithash.a
TARGET_LIB = libmultihash.a
TARGET_BIN = multihash
SRCS = src/hashes.c src/errors.c src/multihash.c

View file

@ -44,7 +44,7 @@ int mh_new_length(int code, size_t digest_len);
* @param digest the data within the multihash
* @returns error (if < 0) or 0
*/
int mh_new(unsigned char *buffer, int code, const unsigned char *digest,
int mh_new(unsigned char* buffer, int code, const unsigned char *digest,
size_t digest_len);
#endif /* end of include guard */

View file

@ -117,7 +117,7 @@ int mh_new_length(int code, size_t hash_len) {
* @param digest the data within the multihash
* @returns error (if < 0) or 0
*/
int mh_new(unsigned char *buffer, int code, const unsigned char *digest,
int mh_new(unsigned char* buffer, int code, const unsigned char *digest,
size_t digest_len) {
if (code & VARINT_MASK)
return MH_E_VARINT_NOT_SUPPORTED;