RobWatlingSF / hedgewars

Automatically exported from code.google.com/p/hedgewars
GNU General Public License v2.0
0 stars 0 forks source link

Bad data or cannot access file theme.cfg #718

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. install software.opensuse.org/package/hedgewars
2. start, play singleplayer, quick game

What is the expected output? What do you see instead?

Failed to install translation (de_DE)
Starting Hedgewars 0.9.19-r9144 (d8a0a7e42b73)
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
Init SDL_Net... ok
Establishing IPC connection to tcp 127.0.0.1:33284 ok
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
[PHYSFS] Failed to open /Missions/Campaign//campaign.ini, reason: no such path
Leaving PAGE_INFO, entering PAGE_MAIN
Generating preview...
Selected template #38 using filter #0
Sending preview...
Preview sent, disconnect
Init SDL_Net... ok
Establishing IPC connection to tcp 127.0.0.1:33284 ok
Generating preview...
Selected template #38 using filter #0
Sending preview...
Preview sent, disconnect
Init SDL_Net... ok
Establishing IPC connection to tcp 127.0.0.1:33284 ok
Generating preview...
Selected template #6 using filter #0
Sending preview...
Preview sent, disconnect
Leaving PAGE_MAIN, entering PAGE_SINGLEPLAYER
Leaving PAGE_SINGLEPLAYER, entering PAGE_INGAME
Hedgewars engine 0.9.19-r9144 (d8a0a7e42b73) with protocol #45
Init SDL... ok
Init SDL_ttf... ok
Init SDL_image... ok
Loading /Graphics/hwengine.png [flags: 8] ok (32x32)
ATTENTION: default value of option force_s3tc_enable overridden by environment.
Number of game controllers: 0
Not using any game controller
Loading progress sprite: Loading /Graphics/Progress.png [flags: 6] ok (324x972)
Getting game config...
Init SDL_Net... ok
Establishing IPC connection to tcp 127.0.0.1:33284 ok
Init sound...ok
Init SDL_mixer... ok
Reading objects info...
Bad data or cannot access file theme.cfg
Leaving PAGE_INGAME, entering PAGE_SINGLEPLAYER
Leaving PAGE_SINGLEPLAYER, entering PAGE_MAIN
Leaving PAGE_MAIN, entering PAGE_SINGLEPLAYER
Leaving PAGE_SINGLEPLAYER, entering PAGE_INGAME
Hedgewars engine 0.9.19-r9144 (d8a0a7e42b73) with protocol #45
Init SDL... ok
Init SDL_ttf... ok
Init SDL_image... ok
Loading /Graphics/hwengine.png [flags: 8] ok (32x32)
ATTENTION: default value of option force_s3tc_enable overridden by environment.
Number of game controllers: 0
Not using any game controller
Loading progress sprite: Loading /Graphics/Progress.png [flags: 6] ok (324x972)
Getting game config...
Init SDL_Net... ok
Establishing IPC connection to tcp 127.0.0.1:33284 ok
[PHYSFS] Failed to open /Names/sm_luigi.cfg, reason: no such path
[PHYSFS] Failed to open /Names/sm_toad.cfg, reason: no such path
[PHYSFS] Failed to open /Names/sm_peach.cfg, reason: no such path
[PHYSFS] Failed to open /Names/sm_luigi.cfg, reason: no such path
[PHYSFS] Failed to open /Names/sm_mario.cfg, reason: no such path
[PHYSFS] Failed to open /Names/sm_daisy.cfg, reason: no such path
Init sound...ok
Init SDL_mixer... ok
Reading objects info...
Bad data or cannot access file theme.cfg
libpng warning: iCCP: known incorrect sRGB profile
Leaving PAGE_INGAME, entering PAGE_SINGLEPLAYER

What version of the product are you using? On what operating system?
I packaged http://download.gna.org/hedgewars/hedgewars-src-0.9.19.3.tar.bz2 
however it needs 2 patches to build:

https://build.opensuse.org/package/view_file/games/hedgewars/hedgewars-fix-physf
s-linking.patch?expand=1

https://build.opensuse.org/package/view_file/games/hedgewars/hedgewars-missing-c
make-module.patch?expand=1

It does not work at all on openSUSE 12.3 and the latest 13.1

Please provide any additional information below.

Contributed the patches at https://github.com/hedgewars/hw/pulls

Will build the hedgewars-server module soon after the Haskell dependencies have 
been packaged/updated.

Original issue reported on code.google.com by mailaend...@gmail.com on 21 Nov 2013 at 8:25

GoogleCodeExporter commented 8 years ago
Please see this issue
https://code.google.com/p/hedgewars/issues/detail?id=665

Original comment by costamag...@gmail.com on 22 Nov 2013 at 2:03

GoogleCodeExporter commented 8 years ago
the patch is completely broken.
Please tell here the problem about building, but I think this can fix it 10 
DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
11 #Helping libc >= 2.17, see launchpad bug #1179850
12 TYPE_FLAGS = -DFPFLAGS="-k/lib/$(DEB_HOST_MULTIARCH)/libgcc_s.so.1"
13
14 DEB_CMAKE_INSTALL_PREFIX := /usr/lib/hedgewars
15 DEB_CMAKE_EXTRA_FLAGS      := -DNOSERVER=0 \
16         -DDATA_INSTALL_DIR=/usr/share/games/hedgewars $(TYPE_FLAGS)
17
18 UPSTREAM_VERSION := $(shell dpkg-parsechangelog \
19         |grep ^Version|awk '{print $$2}'|sed 's/-[[:digit:]]\+$$//' \
20 )

Original comment by costamag...@gmail.com on 22 Nov 2013 at 2:06

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
copy-pasting my irc comments
<LocutusOfBorg1> nemo, I really don't like this patch
<LocutusOfBorg1> 
https://build.opensuse.org/package/view_file/games/hedgewars/hedgewars-fix-physf
s-linking.patch?expand=1
<LocutusOfBorg1> nemo, they use physfs from opensuse
<LocutusOfBorg1> not yours
<LocutusOfBorg1> BuildRequires:  libphysfs-devel
<LocutusOfBorg1> I had a similar FTBFS if you remember, I fixed by manually 
linking -TYPE_FLAGS = -DFPFLAGS="-k/lib/$(DEB_HOST_MULTIARCH)/libgcc_s.so.1"
<LocutusOfBorg1> their patch if i recall correctly is wrong
<LocutusOfBorg1> in debian with the patch hedgewars wasn't starting because of 
localization problems and missing files
<LocutusOfBorg1> so they need to link libgcc manually and drop the bad patch

Original comment by costamag...@gmail.com on 22 Nov 2013 at 2:26

GoogleCodeExporter commented 8 years ago
I don't use system libphysfs because SUSE only packaged the latest stable 2.0.3 
not the bundled 2.1.0.

Can't get the linker stuff to work with -DFPFLAGS="-k/lib/libgcc_s.so.1" to 
work :( 

See 
https://build.opensuse.org/package/rdiff/home:Mailaender:branches:games/hedgewar
s?opackage=hedgewars&oproject=games&rev=8

(9015) Linking /home/abuild/rpmbuild/BUILD/hedgewars-src-0.9.19.3/bin/hwengine
/usr/bin/ld: warning: 
/home/abuild/rpmbuild/BUILD/hedgewars-src-0.9.19.3/bin/link.res contains output 
sections; did you forget -T?
/usr/bin/ld: 
/home/abuild/rpmbuild/BUILD/hedgewars-src-0.9.19.3/bin/libhw_physfs.a(physfs.c.o
): undefined reference to symbol '__divdi3@@GLIBC_2.0'
/usr/bin/ld: note: '__divdi3@@GLIBC_2.0' is defined in DSO /lib/libgcc_s.so.1 
so try adding it to the linker command line
/lib/libgcc_s.so.1: could not read symbols: Invalid operation
hwengine.pas(546,1) Error: (9013) Error while linking
hwengine.pas(546,1) Fatal: (10026) There were 1 errors compiling module, 
stopping
Fatal: (1018) Compilation aborted
Error: /usr/bin/ppc386 returned an error exitcode (normal if you did not 
specify a source file to be compiled)
make[2]: *** [bin/hwengine] Error 1
make[1]: *** [hedgewars/CMakeFiles/hwengine.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....

Original comment by mailaend...@gmail.com on 24 Nov 2013 at 10:07

GoogleCodeExporter commented 8 years ago
According to your changelog this one was EXACTLY the same issue I had in ubuntu 
with arm* platforms.
I fixed it by adding "-DFPFLAGS="-k/lib/$(DEB_HOST_MULTIARCH)/libgcc_s.so.1"
(DEB_HOST_MULTIARCH gets the value based on the builder arch)

do you have any libgcc_s.so.1 in your /lib?
and does it contain __divdi3?

Original comment by costamag...@gmail.com on 24 Nov 2013 at 12:35

GoogleCodeExporter commented 8 years ago
Yes, however I believe the $(DEB_HOST_MULTIARCH) is not required for SUSE:

rpm -qif /lib/libgcc_s.so.1
Name        : libgcc_s1
Version     : 4.8.1_20130909
Release     : 3.2.1
Architecture: i586
Install Date: Do 21 Nov 2013 01:14:49 CET
Group       : System/Base
Size        : 112192
License     : GPL-3.0-with-GCC-exception
Signature   : RSA/SHA256, Fr 04 Okt 2013 08:03:55 CEST, Key ID b88b2fd43dbdc284
Source RPM  : gcc48-4.8.1_20130909-3.2.1.src.rpm
Build Date  : Fr 04 Okt 2013 07:49:55 CEST
Build Host  : cloud136
Relocations : (not relocatable)
Packager    : http://bugs.opensuse.org
Vendor      : openSUSE
URL         : http://gcc.gnu.org/
Summary     : C compiler runtime library
Description :
Libgcc is needed for dynamically linked C programs.
Distribution: openSUSE 13.1

Original comment by mailaend...@gmail.com on 24 Nov 2013 at 7:29

GoogleCodeExporter commented 8 years ago
ok but does it contains the symbol __divdi3?

Original comment by costamag...@gmail.com on 24 Nov 2013 at 9:41

GoogleCodeExporter commented 8 years ago
/usr/bin/ld: note: '__divdi3@@GLIBC_2.0' is defined in DSO /lib/libgcc_s.so.1 
so try adding it to the linker command line

Original comment by mailaend...@gmail.com on 25 Nov 2013 at 2:40

GoogleCodeExporter commented 8 years ago
can you please print "FPFLAGS" just before the linking?

Original comment by costamag...@gmail.com on 25 Nov 2013 at 2:41

GoogleCodeExporter commented 8 years ago
I created patches after getting some advice on IRC

* https://github.com/hedgewars/hw/pull/3 compiles, but leads problems described 
above
* https://github.com/hedgewars/hw/pull/4 does not even compile :(

Original comment by mailaend...@gmail.com on 25 Nov 2013 at 2:42

GoogleCodeExporter commented 8 years ago
Sorry but I don't understand the pull 4

        {$linklib stdc++}
is used if not DARWIN, maybe is

{$IFDEF PHYSFS_INTERNAL}
  {$linklib gcc_s.1}
{$ENDIF}

Original comment by costamag...@gmail.com on 25 Nov 2013 at 2:52

GoogleCodeExporter commented 8 years ago
How do I print and set FPFLAGS properly?

Original comment by mailaend...@gmail.com on 25 Nov 2013 at 2:59

GoogleCodeExporter commented 8 years ago
I don't know, are you trying to build it in your machine or in a clean building 
environment?
export can help

Original comment by costamag...@gmail.com on 25 Nov 2013 at 3:11

GoogleCodeExporter commented 8 years ago
I simplified the patch now 
https://build.opensuse.org/package/view_file/home:Mailaender:branches:games/hedg
ewars/physfs-libgcc-linker.patch?expand=1 as I think you are right. The ifs 
seemed bogus. Still no luck. This is promised to be fixed in .20 so I will give 
up here.

Yes, this is a clean build environment 
https://build.opensuse.org/package/show/home:Mailaender:branches:games/hedgewars
 You can click on the red failed to see the complete logs. I noticed that it 
seems to ignore some cmake parameters. Especially 
-DFPFLAGS="-k/lib/$(DEB_HOST_MULTIARCH)/libgcc_s.so.1 never showed up on the 
command line and I have no idea why.

Original comment by mailaend...@gmail.com on 25 Nov 2013 at 10:26

GoogleCodeExporter commented 8 years ago
Might want to try .20 - is a pain to fix these things after release, if there's 
an actual issue.

Original comment by kyberneticist@gmail.com on 25 Nov 2013 at 11:10

GoogleCodeExporter commented 8 years ago
Where can I download and try .20?

Original comment by mailaend...@gmail.com on 26 Nov 2013 at 8:04

GoogleCodeExporter commented 8 years ago
Mailaender, .20 would be latest dev trunk code.

Adding this since it seems relevant.
02:49 < q_> I'm on slackware and the slackbuild for hedgewars 0.9.19.3 fails 
when running ./hedgewars.SlackBuild, here's the 
            output: http://pastebin.com/GprR7XcJ . Can anyone please help?

==== pastebin below ===
(3104) Compiling uLand.pas
(3104) Compiling uLandTemplates.pas
(3104) Compiling uLandObjects.pas
(3104) Compiling adler32.pas
(3104) Compiling uLandPainted.pas
(3104) Compiling uLandGenMaze.pas
(3104) Compiling uLandOutline.pas
(3104) Compiling uCommandHandlers.pas
(9015) Linking /tmp/SBo/hedgewars-src-0.9.19.3/build/bin/hwengine
/usr/bin/ld: warning: /tmp/SBo/hedgewars-src-0.9.19.3/build/bin/link.res 
contain s output sections; did you forget -T?
/tmp/SBo/hedgewars-src-0.9.19.3/build/bin/libhw_physfs.a(physfs.c.o): In 
functio n `PHYSFS_read':
/tmp/SBo/hedgewars-src-0.9.19.3/misc/libphysfs/physfs.c:2377: undefined 
referenc e to `__divdi3'
/tmp/SBo/hedgewars-src-0.9.19.3/build/bin/libhw_physfs.a(physfs.c.o): In 
functio n `PHYSFS_write':
/tmp/SBo/hedgewars-src-0.9.19.3/misc/libphysfs/physfs.c:2429: undefined 
referenc e to `__divdi3'
hwengine.pas(546,1) Error: (9013) Error while linking
hwengine.pas(546,1) Fatal: (10026) There were 1 errors compiling module, 
stoppin g
Fatal: (1018) Compilation aborted
Error: /usr/bin/ppc386 returned an error exitcode (normal if you did not 
specify  a source file to be compiled)
make[2]: *** [bin/hwengine] Error 1
make[2]: Leaving directory `/tmp/SBo/hedgewars-src-0.9.19.3/build'
make[1]: *** [hedgewars/CMakeFiles/hwengine.dir/all] Error 2
make[1]: Leaving directory `/tmp/SBo/hedgewars-src-0.9.19.3/build'
make: *** [all] Error 2

Original comment by kyberneticist@gmail.com on 2 Dec 2013 at 3:21

GoogleCodeExporter commented 8 years ago
This is the log I get without linking libgcc_s
https://buildd.debian.org/status/fetch.php?pkg=hedgewars&arch=i386&ver=0.9.19.3-
2&stamp=1385999009

I fixed it by adding (in debian)

DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/buildflags.mk
CFLAGS+=$(CPPFLAGS)
CXXFLAGS+=$(CPPFLAGS)

DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
#Helping libc >= 2.17, see launchpad bug #1179850
TYPE_FLAGS = -DFPFLAGS="-k/lib/$(DEB_HOST_MULTIARCH)/libgcc_s.so.1"

DEB_CMAKE_INSTALL_PREFIX := /usr/lib/hedgewars
DEB_CMAKE_EXTRA_FLAGS      := -DNOSERVER=0 \
       -DDATA_INSTALL_DIR=/usr/share/games/hedgewars $(TYPE_FLAGS)

Original comment by costamag...@gmail.com on 3 Dec 2013 at 8:25

GoogleCodeExporter commented 8 years ago
Is the -k a Debianism? I still have not figured out why this does nothing on 
SUSE and is not required on Gentoo.

Original comment by mailaend...@gmail.com on 6 Dec 2013 at 2:37

GoogleCodeExporter commented 8 years ago
no.
Something like
cmake . -DFPFLAGS="-k/lib/blablabla/libgcc_s.so.1"

should do the trick

Original comment by costamag...@gmail.com on 6 Dec 2013 at 2:42

GoogleCodeExporter commented 8 years ago
I can confirm this issue is gone in beta 20. Did a test build at 
https://build.opensuse.org/package/show/home:Mailaender:branches:games/hedgewars

Original comment by mailaend...@gmail.com on 24 Dec 2013 at 11:44

GoogleCodeExporter commented 8 years ago
However requiring an unversioned /usr/lib/libphyslayer.so which is usually for 
developers only, is also ugly and might conflict with other packages.

Original comment by mailaend...@gmail.com on 24 Dec 2013 at 11:57

GoogleCodeExporter commented 8 years ago
It is purely hedgewars lib. Glues physfs, sdl, and provides unifrom mechanism 
to load packages in frontend and engine.

Original comment by unC0Rr on 25 Dec 2013 at 11:05

GoogleCodeExporter commented 8 years ago
I guess this issue can be closed now. 
http://software.opensuse.org/package/hedgewars has been updated.

Original comment by mailaend...@gmail.com on 5 Jan 2014 at 11:21

GoogleCodeExporter commented 8 years ago

Original comment by unC0Rr on 11 May 2015 at 5:06