lh3 / minimap

This repo is DEPRECATED. Please use minimap2, the successor of minimap.
https://github.com/lh3/minimap2
MIT License
106 stars 29 forks source link

Allow injection of CPPFLAGS/LDFLAGS #14

Closed pb-cdunn closed 7 years ago

pb-cdunn commented 7 years ago

We need to provide -I and -L for our zlib.

armintoepfer commented 7 years ago

:+1:

lh3 commented 7 years ago

It is ok to add LDFLAGS.

However, CPPFLAGS is used for the C preprocessor only. It should not appear on the linking line. INCLUDES provides the header path. You should keep that.

lh3 commented 7 years ago

By the way, minimap2 is more sensitive than minimap on pacbio read overlapping. Their usage, output and speed are similar.

pb-cdunn commented 7 years ago

@lh3, Updated per comments.

Note: In a Makefile, if you set INCLUDES=-I., as in:

INCLUDES=-I.
main.o: main.c
    gcc -c $(INCLUDES) main.c

Then the following would override INCLUDES:

make INCLUDES=-Ifoo
# INCLUDES is still just "-Ifoo"; i.e. "-I." is gone!

With GNU make, you could do this (unfortunately to append instead of prepend):

INCLUDES+= -I.

Or this:

INCLUDES:= -I. $(INCLUDES)

But not with POSIX make.

Anyway, your build does not actually need -I. anyway, so I removed that line. Please take a look at the updated version.

lh3 commented 7 years ago

Thanks. Merged.

pb-cdunn commented 7 years ago

Thank you, Dr. Li. And we will definitely try minimap2 when we have time.