diff options
author | Kenji Rikitake <[email protected]> | 2014-11-25 07:13:23 +0900 |
---|---|---|
committer | Kenji Rikitake <[email protected]> | 2014-11-25 07:13:23 +0900 |
commit | 7fe8a2d7c41bb1c4a94d404a6a79b0e694b8dc9e (patch) | |
tree | 2b47b6e5ddfaa88a1def9f97a0564804574427db /plugins/c_src.mk | |
parent | 18b73d5212d7dd88ff68ce845389be07921b6346 (diff) | |
download | erlang.mk-7fe8a2d7c41bb1c4a94d404a6a79b0e694b8dc9e.tar.gz erlang.mk-7fe8a2d7c41bb1c4a94d404a6a79b0e694b8dc9e.tar.bz2 erlang.mk-7fe8a2d7c41bb1c4a94d404a6a79b0e694b8dc9e.zip |
plugins/c_src.mk: use non-regex file extention detection
* The `-regex` option of `find` command to determine `SOURCES` in
plugins/c_src.mk` is not portable; does not work on OS X.
Rewrite with a portable form of using `find` native `-name`
command option with `\(`, `-o`, and `\)`.
* Support file extentions of `*.c`, `*.C`, `*.cc`, and `*.cpp`.
Diffstat (limited to 'plugins/c_src.mk')
-rw-r--r-- | plugins/c_src.mk | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/c_src.mk b/plugins/c_src.mk index 734f13a..87e834b 100644 --- a/plugins/c_src.mk +++ b/plugins/c_src.mk @@ -55,7 +55,7 @@ clean:: $(MAKE) -C $(C_SRC_DIR) clean else -SOURCES := $(shell find $(C_SRC_DIR) -type f -regex ".*\.\(C\|cc?\|cpp\)") +SOURCES := $(shell find $(C_SRC_DIR) -type f \( -name "*.c" -o -name "*.C" -o -name "*.cc" -o -name "*.cpp" \)) OBJECTS = $(addsuffix .o, $(basename $(SOURCES))) COMPILE_C = $(c_verbose) $(CC) $(CFLAGS) $(CPPFLAGS) -c |