Skip to content

Commit

Permalink
Fix MinGW Build (boundarydevices#114)
Browse files Browse the repository at this point in the history
Signed-off-by: Matthew Cattle <[email protected]>
  • Loading branch information
matttcattt authored May 17, 2020
1 parent 25d6c0d commit 30b43d6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Makefile.mingw
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ imx_usb.o : imx_usb.c imx_sdp.h portable.h
%.o : %.c imx_sdp.h portable.h
$(CC) -c $*.c -o $@ -Wstrict-prototypes -Wno-trigraphs -pipe -ggdb $(CFLAGS)

imx_usb: imx_usb.o imx_sdp.o
$(CC) -o $@ [email protected] imx_sdp.o $(LDFLAGS) $(USBLDFLAGS)
imx_usb: imx_usb.o imx_sdp.o imx_loader_config.o sdp.o sdps.o imx_sdp_simulation.o
$(CC) -o $@ [email protected] imx_sdp.o imx_loader_config.o sdp.o sdps.o imx_sdp_simulation.o $(LDFLAGS) $(USBLDFLAGS)

imx_uart: imx_uart.o imx_sdp.o
$(CC) -o $@ [email protected] imx_sdp.o $(LDFLAGS)
imx_uart: imx_uart.o imx_sdp.o imx_loader_config.o sdp.o
$(CC) -o $@ [email protected] imx_sdp.o imx_loader_config.o sdp.o $(LDFLAGS)

clean:
del /f /q imx_usb imx_uart imx_usb.o imx_uart.o imx_sdp.o
Expand Down
2 changes: 2 additions & 0 deletions imx_loader_config.c
Original file line number Diff line number Diff line change
Expand Up @@ -160,12 +160,14 @@ char const *conf_file_name(char const *file, char const *base_path, char const *
if (conf != NULL)
return conf;

#ifndef WIN32
// Fourth priority, conf path relative to base path...
snprintf(path, sizeof(path), "%s/%s", base_path, REL_SYSCONFDIR "/imx-loader.d");
dbg_printf("checking with rel_base_path %s\n", path);
conf = conf_path_ok(path, file);
if (conf != NULL)
return conf;
#endif

printf("%s not found\n", file);
return NULL;
Expand Down

0 comments on commit 30b43d6

Please sign in to comment.