diff --git a/Examples/Makefile.in b/Examples/Makefile.in index 67db611b7..5a1fa7188 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -1472,6 +1472,10 @@ go: $(SRCDIR_SRCS) $(GOPATHPARENTDIR)/go.mod CGO_LDFLAGS="$(LDFLAGS) -lm"; \ export CGO_LDFLAGS; \ (cd $(GOPATHDIR)/ && $(COMPILETOOL) $(GO) build `if $(GOGCC); then echo -compiler=gccgo; fi` -o $(GOPACKAGE)); \ + stat=$$?; \ + if test $$stat != 0; then \ + exit $$stat; \ + fi; \ if $(GOGCC); then \ cp $(GOPATHDIR)/$(GOPACKAGE) $(GOPATHDIR)/$(GOPACKAGE:.a=.gox); \ fi; \ @@ -1480,6 +1484,10 @@ go: $(SRCDIR_SRCS) $(GOPATHPARENTDIR)/go.mod mkdir gopath/$(GOMOD)/src/swigtests/$(INTERFACE:.i=) 2>/dev/null || true; \ cp $(GOPATHDIR)/* gopath/$(GOMOD)/src/swigtests/$(INTERFACE:.i=)/; \ (cd gopath/$(GOMOD)/src/runme && $(COMPILETOOL) $(GO) build `if $(GOGCC); then echo -compiler=gccgo; fi` -o runme $(RUNME).go); \ + stat=$$?; \ + if test $$stat != 0; then \ + exit $$stat; \ + fi; \ cp gopath/$(GOMOD)/src/runme/runme $(RUNME); \ fi @@ -1523,6 +1531,10 @@ go_cpp: $(SRCDIR_SRCS) $(GOPATHPARENTDIR)/go.mod CGO_LDFLAGS="$(LDFLAGS) -lm"; \ export CGO_LDFLAGS; \ (cd $(GOPATHDIR) && $(COMPILETOOL) $(GO) build `if $(GOGCC); then echo -compiler=gccgo; fi` -o $(GOPACKAGE)); \ + stat=$$?; \ + if test $$stat != 0; then \ + exit $$stat; \ + fi; \ if $(GOGCC); then \ cp $(GOPATHDIR)/$(GOPACKAGE) $(GOPATHDIR)/$(GOPACKAGE:.a=.gox); \ fi; \ @@ -1531,6 +1543,10 @@ go_cpp: $(SRCDIR_SRCS) $(GOPATHPARENTDIR)/go.mod mkdir gopath/$(GOMOD)/src/swigtests/$(INTERFACE:.i=) 2>/dev/null || true; \ cp $(GOPATHDIR)/* gopath/$(GOMOD)/src/swigtests/$(INTERFACE:.i=)/; \ (cd gopath/$(GOMOD)/src/runme && $(COMPILETOOL) $(GO) build `if $(GOGCC); then echo -compiler=gccgo; fi` -o runme $(RUNME).go); \ + stat=$$?; \ + if test $$stat != 0; then \ + exit $$stat; \ + fi; \ cp gopath/$(GOMOD)/src/runme/runme $(RUNME); \ fi