kbumsik/opus-media-recorder

make "check_emcc" fails after merged upstream

rowntreerob opened this issue · 4 comments

https://github.com/kbumsik/opus-media-recorder/blob/master/Makefile#L212
throws the following on linux system :

/bin/sh: 1: test: 1.38.34: unexpected operator

causing make target "check_emcc" to fail

RE: https://stackoverflow.com/questions/3411048/unexpected-operator-in-shell-programming

removing one of the "=" in the "==" operator solved the problem.

--- a/Makefile
+++ b/Makefile
@@ -209,7 +209,8 @@ $(DIST_DIR)/%.bin: $(BUILD_DIR)/%.wasm
cc_version = $(shell $(1) --version | head -n1 | cut -d" " -f5)

define check_version

  •   @if test "$$(printf '%s\n' "$(1)" "$(2)" | sort -V | head -2 | tail -1)" == "$(2)"; then \
    
  •   @if test "$$(printf '%s\n' "$(1)" "$(2)" | sort -V | head -2 | tail -1)" = "$(2)"; then \
              exit 0; \
    

@rowntreerob I accepted your suggestion. Thank you for reporting!
Just out of curiosity, which Linux are you using? I'm using Arch Linux and Windows Ubuntu (WSL) but I haven't noticed the problem.

I USE bash shell on ubuntu 16.04

@rowntreerob I see, I will make sure if the build tools work on Ubuntu. Thanks very much for letting me know.