Skip to content
Snippets Groups Projects
Commit f7d8f1d0 authored by rswindell's avatar rswindell
Browse files

Remove any '/' chars from the OS name returned by uname.

parent 4166a77f
Branches
Tags
No related merge requests found
...@@ -57,6 +57,8 @@ endif ...@@ -57,6 +57,8 @@ endif
# this line wont work with solaris unless awk in path is actually gawk # this line wont work with solaris unless awk in path is actually gawk
os := $(shell echo $(os) | tr "[A-Z]" "[a-z]") os := $(shell echo $(os) | tr "[A-Z]" "[a-z]")
#os := $(shell echo $(os) | awk '/.*/ { print tolower($$1)}') #os := $(shell echo $(os) | awk '/.*/ { print tolower($$1)}')
# remove '/' from "os/2"
os := $(shell echo $(os) | tr -d "/")
ifeq ($(os),freebsd) ifeq ($(os),freebsd)
BSD = 1 BSD = 1
......
...@@ -35,6 +35,8 @@ ifndef os ...@@ -35,6 +35,8 @@ ifndef os
$(warning OS not specified on command line, setting to '$(os)'.) $(warning OS not specified on command line, setting to '$(os)'.)
endif endif
os := $(shell echo $(os) | tr "[A-Z]" "[a-z]") os := $(shell echo $(os) | tr "[A-Z]" "[a-z]")
# remove '/' from "os/2"
os := $(shell echo $(os) | tr -d "/")
ODIR := gcc.$(os) ODIR := gcc.$(os)
......
...@@ -23,7 +23,10 @@ ifndef os ...@@ -23,7 +23,10 @@ ifndef os
os = $(shell uname) os = $(shell uname)
$(warning OS not specified on command line, setting to '$(os)'.) $(warning OS not specified on command line, setting to '$(os)'.)
endif endif
os := $(shell echo $(os) | awk '/.*/ { print tolower($$1)}') os := $(shell echo $(os) | tr "[A-Z]" "[a-z]")
# remove '/' from "os/2"
os := $(shell echo $(os) | tr -d "/")
LIBDIR := /usr/lib LIBDIR := /usr/lib
DELETE := rm -f -v DELETE := rm -f -v
......
...@@ -29,7 +29,9 @@ ifndef os ...@@ -29,7 +29,9 @@ ifndef os
os = $(shell uname) os = $(shell uname)
$(warning OS not specified on command line, setting to '$(os)'.) $(warning OS not specified on command line, setting to '$(os)'.)
endif endif
os := $(shell echo $(os) | awk '/.*/ { print tolower($$1)}') os := $(shell echo $(os) | tr "[A-Z]" "[a-z]")
# remove '/' from "os/2"
os := $(shell echo $(os) | tr -d "/")
LIBDIR := /usr/lib LIBDIR := /usr/lib
DELETE := rm -f -v DELETE := rm -f -v
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment