Anodyne

Anodyne

Vezi statistici:
pk 22 mart. 2013 la 22:38
Playing on non-Debian systems
Update: This was resolved. See reply #12.

I'm running Arch Linux and I'm running into the following issue:

[liliff@haruka Anodyne]$ ./bin/Anodyne
Gtk-Message: Failed to load module "canberra-gtk-module"

(Anodyne:28916): GLib-WARNING **: GError set over the top of a previous GError or uninitialized memory.
This indicates a bug in someone's code. You must ensure an error is NULL before it's set.
The overwriting error message was: Failed to execute child process "dpkg" (No such file or directory)

Why is dpkg necessary to run it? I have Adobe AIR installed, so it's not run.sh that's complaining (and for those on arch - install adobe-air-sdk from the AUR create the following symlink: ln -s /opt/adobe-air-sdk/runtimes/air/linux/Adobe\ AIR/ /opt/).

Edit: I also tried making an empty bash script at /usr/bin/dpkg, so now Anodyne doesn't complain, but it doesn't start either.
Editat ultima dată de pk; 27 iul. 2013 la 20:08
< >
Se afișează 1-15 din 29 comentarii
Melos Han-Tani  [dezvoltator] 23 mart. 2013 la 0:02 
I have zero experience with Arch Linux but maybe it's something from how I created that Anodyne binary to begin with. In theory you SHOULD be able to use adt to package it -

Okay, this script I think it packages it and does something with dpkg-deb and then uses that to make the version I put on Steam. I assume if you can just do the packaging only (for the .tar.gz , ignoring the .deb) you might be good to go - I can't really play around with this atm (on windows).

you can ignore the .rpm stuff at the end.

#!/bin/bash

# Where to find the adt executable
ADT="$HOME/Libraries/air_sdk/bin/adt"

# Name for deb package, standalone .tar.gz and rpm
# By default it looks like DefendersQuest_12_13_2010_4_30_PM.deb/.tar.gz/.rpm
TARGET="defenders_quest_$(date +'%m_%d_%Y')"

# Configuration values to change in control/.desktop files
MAINTAINER="whomakesthis>"
VENDOR="company"
URL="website"

# Default values for packaging
SECTION="games"
ARCHITECTURE="all"
DESKTOPCATEGORY="Game;"
RPMGROUP="Amusements/Games"

# Name of top level folder in .tar.gz
FOLDER="DefendersQuest"

# Name of temporary deb file created by ADT
TMPDEB="tmp.deb"

# Filename of RPM build log
RPMLOG="rpmbuild.log"

# Exit on the first error, don't execute the rest of the script
set -e

# Exit if we're trying to use an undefined variable
# (prevents accidental removal of incorrect directories)
set -u

echo "Building deb package with ADT"
$ADT -package -storetype pkcs12 -keystore SelfSigned.pfx \
-storepass REDACTED \
-target native "$TMPDEB" application.xml -C bin .

echo "Extracting deb package"

# Create a temporary directory for the extracted files
DIR="$(mktemp -d)"

# Unpack the installation files
dpkg-deb -x "$TMPDEB" "$DIR"

# Unpack the control files
dpkg-deb --control "$TMPDEB" "$DIR/DEBIAN"

echo "Modifying control file"
# Modify the control file
sed -i"" -e "s/^Maintainer: .\+/Maintainer: $MAINTAINER/" \
-e "s/^Section: .\+/Section: $SECTION/" \
-e "s/^Architecture: .\+/Architecture: $ARCHITECTURE/" \
"$DIR/DEBIAN/control"

echo "Modifying .desktop files"
# Find and modify the .desktop files
find "$DIR" -name "*.desktop" -exec \
sed -i"" -e "s/^Categories=.\+/Categories=$DESKTOPCATEGORY/" {} \;

echo "Extracting game files for standalone package"
# Create target directory
mkdir -p "$FOLDER"

# Remove old game files if they already exist
[[ -d "$FOLDER/bin/" ]] && rm -rf "$FOLDER/bin/"
[[ -d "$FOLDER/share/" ]] && rm -rf "$FOLDER/share/"

# Move the relevant game files into the target directory
find "$DIR/opt" -maxdepth 3 -type d -name "bin" -exec cp -r {} "$FOLDER/" \;
find "$DIR/opt" -maxdepth 3 -type d -name "share" -exec cp -r {} "$FOLDER/" \;

echo "Re-packaging deb package"
# Re-pack the .deb package
dpkg -b "$DIR" "${TARGET}.deb"

echo "Building standalone package"
tar czf "${TARGET}.tar.gz" "$FOLDER"

echo "Removing temporary files"

# Remove the temporary directory
rm -rf "$DIR"

# Remove the incorrect deb package created by ADT
rm -f "$TMPDEB"

# Build RPM
echo "Preparing RPM build"

# Set PATH so the fake rpm script is in front of the normal rpm
PATH="./tools${PATH:+:$PATH}"

# Check if rpm and dpkg overrides work properly
rpm -q rpm > /dev/null || { echo "RPM override not set up correctly, check tools directory"; exit 1; }
dpkg -l dpkg > /dev/null && { echo "DPKG override not set up correctly, check tools directory"; exit 1; }

# Export some variables used by rpmbuild
export MAINTAINER VENDOR URL RPMLOG RPMGROUP

# Remove old log
rm -f "$RPMLOG"

# Build the RPM
echo "Building RPM with ADT"
$ADT -package -storetype pkcs12 -keystore SelfSigned.pfx \
-storepass REDACTED \
-target native "${TARGET}.rpm" application.xml -C bin . 3>&1

echo "RPM build log:"
cat "$RPMLOG"

# Unset exported variables
unset MAINTAINER VENDOR URL RPMLOG RPMGROUP

echo ""
echo "Done."
echo "deb package: $(file "${TARGET}.deb")"
echo "RPM package: $(file "${TARGET}.rpm")"
echo "tar.gz: ${TARGET}.tar.gz"

Same issue is also present on the desura version of the game on Arch Linux 64 bit. Isn't there a way to bypass this dpkg check?
pk 23 mart. 2013 la 7:07 
I can't quite find a .deb for Anodyne anywhere in my steampath. What should I be attempting to package with adt?
Hyeron 23 mart. 2013 la 10:49 
Postat inițial de a.fettouhi:
Same issue is also present on the desura version of the game on Arch Linux 64 bit. Isn't there a way to bypass this dpkg check?
The odd thing is... Usually (Defender's Quest, Telepath Tactics and so on) you'd just zip the share folder and be off to play. Here it throws an error. Googling a bit gets you to add
<supportedProfiles>extendedDesktop</supportedProfiles>
to the application.xml. Trying to adobe-air whatever.zip then results in a black screen, with no console output to further look for issues.
Running it straight obviously doesn't work either.
And this is where I give up with this game, this dev, and this amount of money. I'm *sick and tired* of being treated as a 4th grade customer and a nerd supposed to do what retailers won't do - e.g. support an OS rather than a single variant of the OS (HEY! THIS RUNS ON ANDROID! Only on Southwest India Galaxy S with Gingerbread, nothing else!), and make sure it runs on more than one computer. I'm buying games to have fun, not spend hours debugging. This one was once too many.
Sorry, just needed to vent for a bit. If the above information helps, feel free to pick up from here.
Melos Han-Tani  [dezvoltator] 23 mart. 2013 la 11:13 
Postat inițial de Hyeron:
Postat inițial de a.fettouhi:
Same issue is also present on the desura version of the game on Arch Linux 64 bit. Isn't there a way to bypass this dpkg check?
The odd thing is... Usually (Defender's Quest, Telepath Tactics and so on) you'd just zip the share folder and be off to play. Here it throws an error. Googling a bit gets you to add
<supportedProfiles>extendedDesktop</supportedProfiles>
to the application.xml. Trying to adobe-air whatever.zip then results in a black screen, with no console output to further look for issues.
Running it straight obviously doesn't work either.
And this is where I give up with this game, this dev, and this amount of money. I'm *sick and tired* of being treated as a 4th grade customer and a nerd supposed to do what retailers won't do - e.g. support an OS rather than a single variant of the OS (HEY! THIS RUNS ON ANDROID! Only on Southwest India Galaxy S with Gingerbread, nothing else!), and make sure it runs on more than one computer. I'm buying games to have fun, not spend hours debugging. This one was once too many.
Sorry, just needed to vent for a bit. If the above information helps, feel free to pick up from here.

I can send you a standalone SWF version if you want.

I was saying that maybe the dpkg thing might come from how that script works, it looks like it ubilds hte .deb and then takes stuff out of there for the version I put on Steam and Desura. Maybe if you just try the adt stuff by itself youll have luck. ill see if i can make a version without the deb stuff coming first.
Melos Han-Tani  [dezvoltator] 23 mart. 2013 la 11:15 
Postat inițial de lae:
I can't quite find a .deb for Anodyne anywhere in my steampath. What should I be attempting to package with adt?

it should just be the contents of the share folder. youll need to point hte adt command to the cert and xml file though . i think the DEB environment variable can be replaced with the name of another folder, i'l have to check though
a.fettouhi 23 mart. 2013 la 14:49 
It is strange why it throws out the dpkg error when the game is already installed.
pk 23 mart. 2013 la 15:18 
I thought it would have been the share folder. Where do I find the cert, though? I'm assuming I would run something like this to package an air application:

/opt/adobe-air-sdk/bin/adt -package -storetype pkcs12 -keystore $PATH_TO_PFX anodyne.air share/META-INF/AIR/application.xml -C share .
(while in the Anodyne directory)

I guessed share/META-INF/AIR/hash might have been a key so I tried using that, but was asked for a password, which seems to be the case with any other file so I'm not quite sure if that's it, or what the password is. Is it something in share/META-INF/signatures.xml by any chance?
Editat ultima dată de pk; 23 mart. 2013 la 15:20
Melos Han-Tani  [dezvoltator] 23 mart. 2013 la 15:21 
sorry to forget to give this info:

the cert is anodyne.ssp4 .

password is 'fd'
pk 23 mart. 2013 la 15:28 
Is anodyne.ssp4 supposed to be a file made up of JSON? I'm attempting to using it with that password but it's failing.

edit:
[liliff@haruka share]$ /opt/adobe-air-sdk/bin/adt -package -storetype pkcs12 -keystore anodyne.ssp4 -storepass fd anodyne.air META-INF/AIR/application.xml .
could not load keystore file (password may be incorrect)

second edit:
Though, I still feel like something is missing. What exactly is the Anodyne binary in /bin made from? It doesn't look like it's the output of the packaging script you pasted above.
Editat ultima dată de pk; 23 mart. 2013 la 15:38
Melos Han-Tani  [dezvoltator] 23 mart. 2013 la 17:30 
wow, I am out of it, that is not the cert file at all. here it is: https://dl.dropbox.com/u/53835171/Anodyne.p12

sorry for the trouble :/
pk 23 mart. 2013 la 19:21 
So, I ended up with a really simple solution after figuring out how Adobe Air works and all:

Like Hyeron mentioned above, add this to application.xml within the <application> element:
<supportedProfiles>extendedDesktop</supportedProfiles>

And, in run.sh, you can replace everything (sans the export of LD_LIBRARY_PATH) with:

/opt/adobe-air-sdk/bin/adl share/META-INF/AIR/application.xml share/

Then run it in Steam. Of course, /opt/adobe-air-sdk/bin/adl might point to somewhere else on your distro.

Sean, here is what I would add for Arch to run.sh (as well as adding extendedDesktop to application.xml):

DISTRO=$(lsb_release -si | tr '[A-Z]' '[a-z]')
if []; then
if []; then
xterm -e 'echo "Adobe AIR is missing. Install adobe-air-sdk from the AUR.";read'
exit 1
fi
/opt/adobe-air-sdk/bin/adl share/META-INF/AIR/application.xml share/
fi

I don't know how you'd want to manage that in run.sh, but that's some place to start.

And now I'm going to go finally play Anodyne. :D

edit: as an additional note, lsb_release is something that should be in most distros (in other words, in distros people actually use).
Editat ultima dată de pk; 3 mai 2014 la 20:05
redw0lf 10 apr. 2013 la 12:29 
the last comment helped a lot. now i am able to play as well
...And this is where I give up with this game, this dev, and this amount of money. I'm *sick and tired* of being treated as a 4th grade customer and a nerd supposed to do what retailers won't do - e.g. support an OS rather than a single variant of the OS (HEY! THIS RUNS ON ANDROID! Only on Southwest India Galaxy S with Gingerbread, nothing else!), and make sure it runs on more than one computer. I'm buying games to have fun, not spend hours debugging. This one was once too many.
Sorry, just needed to vent for a bit. If the above information helps, feel free to pick up from here.

+1

11bit studios was negligent of their linux customer base with NVIDIA cards for Anomoly 2. This is the second game in a row that I have paid for which is advertised to run on linux but does not, in fact, run on linux (at least my computer). That said, I LOVE what steam has done for independent game and soundtrack developers, and I love that these 'indie' developers have REAL dialogue with their customers, actually listen to feedback, and do what they do because they love what they do. But the transparency and compatibility issues are still a far cry from the smoothness of the open source model ;). I think we will continue to have headaches like this until open source takes over. Just look at Xonotic, Nexuiz, and Alien Arena to name a few. Great games, work on ALL distros flawlessly, and turn a profit for their devs.



Postat inițial de redw0lf:
the last comment helped a lot. now i am able to play as well

+1

Thank you lae! I haven't tried through steam yet but I can finally play the game with run.sh (Arch Linux user). You're the best.

Edit: I tried your method with the steam downloaded files and it worked that way as well. Thanks again!
Editat ultima dată de LogicalPhallusy; 26 iun. 2013 la 23:13
pk 18 iun. 2013 la 1:01 
You're most welcome.
< >
Se afișează 1-15 din 29 comentarii
Per pagină: 1530 50