summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bsd_eth_drivers/ChangeLog4
-rw-r--r--bsd_eth_drivers/links.am8
2 files changed, 7 insertions, 5 deletions
diff --git a/bsd_eth_drivers/ChangeLog b/bsd_eth_drivers/ChangeLog
index c600c23..3870355 100644
--- a/bsd_eth_drivers/ChangeLog
+++ b/bsd_eth_drivers/ChangeLog
@@ -1,3 +1,7 @@
+2010-03-07 Till Straumann <Till.Straumann@TU-Berlin.de>
+
+ * links.am: POSIXified sed commands for sake of portability.
+
2010-02-12 Till Straumann <Till.Straumann@TU-Berlin.de>
* libbsdport/Makefile.am: Removed obsolete (and commented)
diff --git a/bsd_eth_drivers/links.am b/bsd_eth_drivers/links.am
index 6add846..1f068a2 100644
--- a/bsd_eth_drivers/links.am
+++ b/bsd_eth_drivers/links.am
@@ -4,17 +4,15 @@ $(DUMMYHEADERS):
@if [ ! -d `dirname $@` ] ; then mkdir -p `dirname $@`; fi
@touch $@
-# if [ "$(echo $@ | sed -e 's/^\/.*/yes/')" = "yes" ]; then
-
$(LINKS):
echo $@
if [ ! -d $(dir $@) ] ; then mkdir -p $(dir $@); fi
if [ ! -e $@ ]; then \
rm -rf $@ ; \
- if [ "`echo $(srcdir) | sed -e 's/^\/.*/yes/'`" = "yes" ]; then \
- ln -s `echo $(dir $@) | sed -e 's%[^/]\+[/]\+%%g'`$(srcdir)/$(notdir $@) $@ ; \
+ if [ "`echo $(srcdir) | sed -e 's%^/.*%yes%'`" = "yes" ]; then \
+ ln -s `echo $(dir $@) | sed -e 's%[^/][^/]*[/][/]*%%g'`$(srcdir)/$(notdir $@) $@ ; \
else \
- ln -s `echo $(dir $@) | sed -e 's%[^/]\+[/]\+%../%g'`$(srcdir)/$(notdir $@) $@ ; \
+ ln -s `echo $(dir $@) | sed -e 's%[^/][^/]*[/][/]*%../%g'`$(srcdir)/$(notdir $@) $@ ; \
fi ; \
fi