Project

General

Profile

Actions

Backport #3437

closed

Does not compile on Windows with Visual Studio

Added by Octagon (Andrey Gerasimenko) almost 14 years ago. Updated almost 5 years ago.

Status:
Closed
[ruby-core:30757]

Description

=begin
When compiled with Visual Studio, compilation fails with the error message "cannot parse and attach manifest, file not found".

OS: Windows 7

Since ruby is more or less OK without a manifest, just entering "nmake" again allows to advance further and finally get ruby compiled.

With VS 2008 it is necessary to resume nmake about 3 times, just when final executables are being built. With VS 2010 it is necessary to resume nmake very many times.
=end

Actions #1

Updated by usa (Usaku NAKAMURA) almost 14 years ago

  • Status changed from Open to Assigned
  • Assignee set to yugui (Yuki Sonoda)

=begin
yugui-san, please commit this patch.
this is a part of r25173, and already backported to ruby_1_8, ruby_1_8_7.
Only ruby_1_9_1 and ruby_1_8_6 haven't backported it.

Index: win32/Makefile.sub

--- win32/Makefile.sub (revision 28315)
+++ win32/Makefile.sub (working copy)
@@ -629,9 +629,9 @@ s,@RPATHFLAG@,,;t t
s,@LIBARG@,%s.lib,;t t
s,@LINK_SO@,$$(LDSHARED) -Fe$$(@) $$(OBJS) $$(LIBS) $$(LOCAL_LIBS) -link $$(DLDFLAGS) -implib:$$(*F:.so=)-$$(arch).lib -pdb:$$(*F:.so=)-$$(arch).pdb -def:$$(DEFFILE),;t t
!if $(MSC_VER) >= 1400
-s,@LINK_SO@,@$$(RUBY) -run -e wait_writable -- -n 10 $$(@),;t t
-s,@LINK_SO@,$(MANIFESTTOOL) -manifest $$(@).manifest -outputresource:$$(@);2,;t t
-s,@LINK_SO@,@$$(RM) $$(@:/=).manifest,;t t
+s,@LINK_SO@,@if exist $$(@).manifest $$(RUBY) -run -e wait_writable -- -n 10 $$(@),;t t
+s,@LINK_SO@,@if exist $$(@).manifest $(MANIFESTTOOL) -manifest $$(@).manifest -outputresource:$$(@);2,;t t
+s,@LINK_SO@,@if exist $$(@).manifest $$(RM) $$(@:/=).manifest,;t t
!endif
s,@COMPILE_C@,$$(CC) $$(INCFLAGS) $$(CFLAGS) $$(CPPFLAGS) $$(COUTFLAG)$$(@) -c -Tc$$(<:=/),;t t
s,@COMPILE_CXX@,$$(CXX) $$(INCFLAGS) $$(CXXFLAGS) $$(CPPFLAGS) $$(COUTFLAG)$$(@) -c -Tp$$(<:=/),;t t

=end

Actions #2

Updated by jeremyevans0 (Jeremy Evans) almost 5 years ago

  • Description updated (diff)
  • Status changed from Assigned to Closed
Actions

Also available in: Atom PDF

Like0
Like0Like0