Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Texplay 4.4 does not compile on Windows - Ruby 2.0.0 (32-bit) #27

Open
burtlo opened this issue Aug 28, 2014 · 1 comment
Open

Texplay 4.4 does not compile on Windows - Ruby 2.0.0 (32-bit) #27

burtlo opened this issue Aug 28, 2014 · 1 comment

Comments

@burtlo
Copy link
Contributor

burtlo commented Aug 28, 2014

Attempted to build this against commit 22ff506. It fails.

PS C:\source\texplay> rake compile
Temporarily enhancing PATH to include DevKit...
cd tmp/i386-mingw32/texplay/2.0.0
make
compiling ../../../../ext/texplay/actions.c
In file included from c:/Ruby/include/ruby-2.0.0/ruby/defines.h:153:0,
                 from c:/Ruby/include/ruby-2.0.0/ruby/ruby.h:70,
                 from c:/Ruby/include/ruby-2.0.0/ruby.h:33,
                 from ../../../../ext/texplay/texplay.h:10,
                 from ../../../../ext/texplay/actions.c:1:
c:/Ruby/include/ruby-2.0.0/ruby/win32.h: In function 'rb_w32_pow':
c:/Ruby/include/ruby-2.0.0/ruby/win32.h:801:5: warning: implicit declaration of function '_controlfp' [-Wimplicit-functi
on-declaration]
c:/Ruby/include/ruby-2.0.0/ruby/win32.h:802:16: error: '_PC_64' undeclared (first use in this function)
c:/Ruby/include/ruby-2.0.0/ruby/win32.h:802:16: note: each undeclared identifier is reported only once for each function
 it appears in
c:/Ruby/include/ruby-2.0.0/ruby/win32.h:802:24: error: '_MCW_PC' undeclared (first use in this function)
../../../../ext/texplay/actions.c: In function 'line_do_action':
../../../../ext/texplay/actions.c:57:5: warning: passing argument 2 of 'has_optional_hash_arg' discards 'const' qualifie
r from pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:66:6: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:58:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from p
ointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:60:5: warning: passing argument 2 of 'has_optional_hash_arg' discards 'const' qualifie
r from pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:66:6: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:61:7: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from p
ointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:69:7: warning: passing argument 2 of 'has_optional_hash_arg' discards 'const' qualifie
r from pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:66:6: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:70:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from p
ointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:74:7: warning: passing argument 2 of 'has_optional_hash_arg' discards 'const' qualifie
r from pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:66:6: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:75:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from p
ointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:118:17: warning: passing argument 2 of 'set_hash_value' discards 'const' qualifier fro
m pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:57:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:146:17: warning: passing argument 2 of 'set_hash_value' discards 'const' qualifier fro
m pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:57:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:171:9: warning: passing argument 2 of 'set_hash_value' discards 'const' qualifier from
 pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:57:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c: In function 'polyline_do_action':
../../../../ext/texplay/actions.c:235:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:235:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c: In function 'ngon_do_action':
../../../../ext/texplay/actions.c:302:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:303:13: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
 pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:312:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:313:13: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
 pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c: In function 'rect_do_action':
../../../../ext/texplay/actions.c:354:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:354:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:358:13: warning: passing argument 2 of 'delete_from_hash' discards 'const' qualifier f
rom pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:60:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:360:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:361:13: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
 pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c: In function 'circle_do_action':
../../../../ext/texplay/actions.c:409:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:409:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:414:13: warning: passing argument 2 of 'delete_from_hash' discards 'const' qualifier f
rom pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:60:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c: In function 'flood_fill_do_action':
../../../../ext/texplay/actions.c:500:16: warning: variable 'nMinY' set but not used [-Wunused-but-set-variable]
../../../../ext/texplay/actions.c: In function 'glow_fill_do_action':
../../../../ext/texplay/actions.c:630:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c: In function 'bezier_do_action':
../../../../ext/texplay/actions.c:818:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:818:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:826:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:827:13: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
 pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c: In function 'splice_do_action':
../../../../ext/texplay/actions.c:963:5: warning: passing argument 2 of 'has_optional_hash_arg' discards 'const' qualifi
er from pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:66:6: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:964:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:968:5: warning: passing argument 2 of 'has_optional_hash_arg' discards 'const' qualifi
er from pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:66:6: note: expected 'char *' but argument is of type 'const char *'
../../../../ext/texplay/actions.c:969:9: warning: passing argument 2 of 'get_from_hash' discards 'const' qualifier from
pointer target type [enabled by default]
In file included from ../../../../ext/texplay/actions.c:2:0:
../../../../ext/texplay/utils.h:54:7: note: expected 'char *' but argument is of type 'const char *'
make: *** [actions.o] Error 1
rake aborted!
Command failed with status (2): [make...]

Tasks: TOP => compile => compile:i386-mingw32 => compile:texplay:i386-mingw32 => copy:texplay:i386-mingw32:2.0.0 => tmp/
i386-mingw32/texplay/2.0.0/texplay.so
(See full trace by running task with --trace)
@burtlo burtlo changed the title Texplay does not compile on Windows - Ruby 2.0.0 Texplay 4.4 does not compile on Windows - Ruby 2.0.0 Aug 28, 2014
@burtlo burtlo changed the title Texplay 4.4 does not compile on Windows - Ruby 2.0.0 Texplay 4.4 does not compile on Windows - Ruby 2.0.0 (32-bit) Aug 28, 2014
@burtlo
Copy link
Contributor Author

burtlo commented Aug 28, 2014

c:/Ruby/include/ruby-2.0.0/ruby/win32.h:802:16: error: '_PC_64' undeclared (first use in this function)

This first error looks like it could be solved by installing ruby-2.0.0x64. However, that creates a whole host of issues with Gosu. I am able to install gosu if I override the platform but I don't know how you would specify "x64-mingw32" platform in the texplay runtime dependency s.add_runtime_dependency("gosu",">=0.7.25").

I tried to workaround that in two different ways

  • removing it as a dependency
  • building a special gosu version for the platform "x64-mingw32"

Ultimately it doesn't matter because when I compile it fails:

PS C:\source\texplay> rake compile
Temporarily enhancing PATH to include DevKit...
mkdir -p tmp/x64-mingw32/texplay/2.0.0
cd tmp/x64-mingw32/texplay/2.0.0
C:/Ruby/bin/ruby.exe -I. ../../../../ext/texplay/extconf.rb
checking for main() in -lfreeglut_static... no
*** ../../../../ext/texplay/extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers.  Check the mkmf.log file for more details.  You may
need configuration options.

Provided configuration options:
        --with-opt-dir
        --without-opt-dir
        --with-opt-include
        --without-opt-include=${opt-dir}/include
        --with-opt-lib
        --without-opt-lib=${opt-dir}/lib
        --with-make-prog
        --without-make-prog
        --srcdir=../../../../ext/texplay
        --curdir
        --ruby=C:/Ruby/bin/ruby
        --with-texplay/texplay-dir
        --without-texplay/texplay-dir
        --with-texplay/texplay-include
        --without-texplay/texplay-include=${texplay/texplay-dir}/include
        --with-texplay/texplay-lib
        --without-texplay/texplay-lib=${texplay/texplay-dir}/
        --with-freeglut_staticlib
        --without-freeglut_staticlib
rake aborted!
Command failed with status (1): [C:/Ruby/bin/ruby.exe -I. ../../../../ext/t...]

Tasks: TOP => compile => compile:x64-mingw32 => compile:texplay:x64-mingw32 => copy:texplay:x64-mingw32:2.0.0 => tmp/x6
-mingw32/texplay/2.0.0/texplay.so => tmp/x64-mingw32/texplay/2.0.0/Makefile
(See full trace by running task with --trace)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant