Skip to content

Commit 6a97d97

Browse files
committed
Fix unexpected operator build error on POSIX shells
'==' comparison operator is only supported by Bash, while '=' is supported by both Bash and standard POSIX shells.
1 parent e17af39 commit 6a97d97

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ $(WHAT): validate-go-version
127127
@$(WHAT_$@_BUILD_FLAGS) go build -mod=vendor $(VERBOSE_$(V)) -o bin/$@ $(LDFLAGS) ./cmd/$@
128128

129129
# special case: if the current WHAT is o2-aliecs-executor, also copy over the shmcleaner script
130-
@if [ $@ == "o2-aliecs-executor" ]; then \
130+
@if [ $@ = "o2-aliecs-executor" ]; then \
131131
echo -e "\033[1;33mcopy\033[0m ./o2-aliecs-shmcleaner \033[1;33m==>\033[0m \033[1;34m./bin/o2-aliecs-shmcleaner\033[0m"; \
132132
cp o2-aliecs-shmcleaner bin/o2-aliecs-shmcleaner; \
133133
chmod +x bin/o2-aliecs-shmcleaner; \
@@ -140,7 +140,7 @@ $(INSTALL_WHAT): validate-go-version
140140
@$(WHAT_$(@:install_%=%)_BUILD_FLAGS) go install -mod=vendor $(VERBOSE_$(V)) $(LDFLAGS) ./cmd/$(@:install_%=%)
141141

142142
# special case: if the current WHAT is o2-aliecs-executor, also copy over the shmcleaner script
143-
@if [ $@ == "install_o2-aliecs-executor" ]; then \
143+
@if [ $@ = "install_o2-aliecs-executor" ]; then \
144144
echo -e "\033[1;33minstall\033[0m ./o2-aliecs-shmcleaner \033[1;33m==>\033[0m \033[1;34m$$GOPATH/bin/o2-aliecs-shmcleaner\033[0m"; \
145145
cp o2-aliecs-shmcleaner $${GOPATH}/bin/o2-aliecs-shmcleaner; \
146146
chmod +x $${GOPATH}/bin/o2-aliecs-shmcleaner; \

0 commit comments

Comments
 (0)