Actions

icon Post
text/html Subscribe
text/html Unsubscribe

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

patch: Fix Windows build issues.


  • To: VSIPL++ Developers List <vsipl++@xxxxxxxxxxxxxxxx>
  • Subject: patch: Fix Windows build issues.
  • From: Stefan Seefeld <stefan@xxxxxxxxxxxxxxxx>
  • Date: Sun, 23 Dec 2007 23:08:29 -0500

The attached patch corrects various issues raised during automated
testing on Windows ('make benchmarks'). Checked in as obvious.

Thanks,
		Stefan

-- 
Stefan Seefeld
CodeSourcery
stefan@xxxxxxxxxxxxxxxx
(650) 331-3385 x718
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 190020)
+++ ChangeLog	(working copy)
@@ -1,3 +1,10 @@
+2007-12-23  Stefan Seefeld  <stefan@xxxxxxxxxxxxxxxx>
+
+	* GNUmakefile.in: Correct link_app and link_csl_app definitions.
+	* benchmarks/GNUmakefile.inc.in: Use them.
+	* benchmarks/hpec_kernel/GNUmakefile.inc.in: Likewise.
+	* benchmarks/memwrite_simd.cpp: Fix test() signature.
+
 2007-12-21  Brooks Moses  <brooks@xxxxxxxxxxxxxxxx>
 
 	Ported from branches/afrl-ncet:
Index: GNUmakefile.in
===================================================================
--- GNUmakefile.in	(revision 190020)
+++ GNUmakefile.in	(working copy)
@@ -198,12 +198,20 @@
 
 define link_app
 @echo linking $@
-xilink /nologo /out:$@ $< /libpath:lib libsvpp.lib \
+xilink /nologo /out:$@ $^ /libpath:lib libsvpp.lib \
   $(subst -L,/libpath:, $(call dir_var,$(dir $<),LDFLAGS)) \
   $(patsubst -l%,lib%.lib, \
     $(subst -L,/libpath:, $(call dir_var,$(dir $<),LIBS) $(LIBS)))
 endef
 
+define link_csl_app
+@echo linking $@
+xilink /nologo /out:$@ $^ /libpath:lib libvsip_csl.lib libsvpp.lib \
+  $(subst -L,/libpath:, $(call dir_var,$(dir $<),LDFLAGS)) \
+  $(patsubst -l%,lib%.lib, \
+    $(subst -L,/libpath:, $(call dir_var,$(dir $<),LIBS) $(LIBS)))
+endef
+
 else # not intel-win
 
 # Generate dependencies (This recipe is modified from the GNU Make manual.)
@@ -237,14 +245,14 @@
 
 define link_app
 @echo linking $@
-$(CXX) $(LDFLAGS) $(call dir_var,$(dir $<),LDFLAGS) -o $@ $< \
+$(CXX) $(LDFLAGS) $(call dir_var,$(dir $<),LDFLAGS) -o $@ $^ \
   -Llib -lsvpp $(call dir_var,$(dir $<),LIBS) $(LIBS)
 endef
 
 define link_csl_app
 @echo linking $@
-$(CXX) $(LDFLAGS) $(call dir_var,$(dir $<),LDFLAGS) -o $@ $< \
-  -Llib -lsvpp -lvsip_csl $(call dir_var,$(dir $<),LIBS) $(LIBS)
+$(CXX) $(LDFLAGS) $(call dir_var,$(dir $<),LDFLAGS) -o $@ $^ \
+  -Llib -lvsip_csl -lsvpp $(call dir_var,$(dir $<),LIBS) $(LIBS)
 endef
 
 endif
Index: benchmarks/GNUmakefile.inc.in
===================================================================
--- benchmarks/GNUmakefile.inc.in	(revision 190020)
+++ benchmarks/GNUmakefile.inc.in	(working copy)
@@ -105,7 +105,7 @@
 	done
 
 $(benchmarks_targets): %$(EXEEXT) : %.$(OBJEXT) benchmarks/main.$(OBJEXT) $(libs)
-	$(CXX) $(LDFLAGS) -o $@ $^ -Llib -lsvpp $(LIBS) || rm -f $@
+	$(link_app)
 
 $(benchmarks_static_targets): %.static$(EXEEXT) : %.$(OBJEXT) benchmarks/main.$(OBJEXT) $(libs)
 	$(CXX) -static $(LDFLAGS) -o $@ $^ -Llib -lsvpp $(LIBS) || rm -f $@
Index: benchmarks/hpec_kernel/GNUmakefile.inc.in
===================================================================
--- benchmarks/hpec_kernel/GNUmakefile.inc.in	(revision 190020)
+++ benchmarks/hpec_kernel/GNUmakefile.inc.in	(working copy)
@@ -63,8 +63,7 @@
 	  $(INSTALL) $$binfile $(DESTDIR)$(exec_prefix)/`dirname $$binfile`; \
 	done
 
-$(hpec_targets): %$(EXEEXT) : \
-  %.$(OBJEXT) benchmarks/main.$(OBJEXT) $(libs)
-	$(CXX) $(LDFLAGS) -o $@ $^ -Llib -lsvpp $(LIBS) || rm -f $@
+$(hpec_targets): %$(EXEEXT) : %.$(OBJEXT) benchmarks/main.$(OBJEXT) $(libs)
+	$(link_app)
 
 endif
Index: benchmarks/memwrite_simd.cpp
===================================================================
--- benchmarks/memwrite_simd.cpp	(revision 190020)
+++ benchmarks/memwrite_simd.cpp	(working copy)
@@ -165,7 +165,7 @@
 
 
 
-void
+int
 test(Loop1P& loop, int what)
 {
   typedef complex<float> cf_type;
@@ -173,5 +173,7 @@
   {
   case  1: loop(t_memwrite_simd<float>()); break;
   case  2: loop(t_memwrite_simd_r4<float>()); break;
+  default: return 0;
   }
+  return 1;
 }