Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 318945 - Better detection of the nwn discs in nwn-data.
Summary: Better detection of the nwn discs in nwn-data.
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Games (show other bugs)
Hardware: x86 Linux
: High enhancement (vote)
Assignee: Denis Dupeyron (RETIRED)
URL:
Whiteboard:
Keywords: NeedPatch
Depends on:
Blocks:
 
Reported: 2010-05-08 06:03 UTC by Myckel Habets
Modified: 2012-12-15 17:13 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Myckel Habets 2010-05-08 06:03:27 UTC
While testing for bug 307373 I found out that the NWN HotU XP2 cd is recognized as the Neverwinter Nights Platinum DVD/CD set, when it is mounted in the cd drive and the install is started. This leads to trying to copy the wrong files, error messages about files not found and asking for the second disc that does not exists. 

The ebuild determines the type of cd based on one file that is also present on the HotU XP2 cd. This is incorrect and the ebuild should have a more robust method of detecting the correct disc.

One possible way could be to calculate the md5sum of some files and determine the type of cd based on that.
For the HotU-XP2 cd the md5sums of the files in the cd root are (the readme.txt might be the most useful in this case):

b0c5479dd84afcf202e9f4c8e1d90b23  /mnt/cdrom/AUTORUN.INF
f40285fc9652fd327731c415aef29487  /mnt/cdrom/AcroReader51_ENU.exe
f1f3b1ad503a196270f9ce4bc23d8d85  /mnt/cdrom/ArcadeInstallNWNXP213f.EXE
b8668f43f2ac7c726a0df2ad4783813d  /mnt/cdrom/CriticalRebuild.exe
feff5f08197ed1ea8e1521e67c92ba20  /mnt/cdrom/CriticalRebuild.ini
a23d596c8a0c87ecd55be4fbf10317c8  /mnt/cdrom/Data_Shared.zip
904b67a4b1f25a266a8475e372d4fcc0  /mnt/cdrom/EULA.txt
47a0d3aa22ced79971e8670e07e058a6  /mnt/cdrom/Language_data.zip
f2eea0220f1c70782dda27064345e12a  /mnt/cdrom/Language_update.zip
e33008f24bbbbc079029ae4429293199  /mnt/cdrom/NWN Hordes Install Guide.rtf
1aeb989e361af85f5099de3da25457f4  /mnt/cdrom/Setup.exe
ee4f20dec6f6af7e88d23861e792a89c  /mnt/cdrom/Setup.ini
e50580da481662277702f32ed703d9c3  /mnt/cdrom/autorun.exe
0149e185abe2b93e40047a020e34a2d5  /mnt/cdrom/data1.cab
f219208ae9f4292afc8b5f8e67ca38c7  /mnt/cdrom/data1.hdr
6f66196962f2d78a0c86ec91bec7ef9a  /mnt/cdrom/data2.cab
93b63f516482715a784bbec3a0bf5f3a  /mnt/cdrom/ikernel.ex_
c182912d215b8c31b21189c62b0be88d  /mnt/cdrom/layout.bin
40ff54a04c0f454f62765f0dd2448138  /mnt/cdrom/nwn.ico
f6bb3f6bf0caed14d1ab0f1dea44f293  /mnt/cdrom/readme.txt
03a01d22277ffc06f91b475696946b81  /mnt/cdrom/setup.bmp
ab82958b7aa94eaad1600b616e04f110  /mnt/cdrom/setup.inx

Reproducible: Always

Steps to Reproduce:
1. emerge nwn-data with HotU XP2 cd already mounted.
2.
3.

Actual Results:  
Neverwinter Nights Platinum DVD/CD set found...
Data installed from the HotU XP2 cd.


Expected Results:  
Error about the wrong disc in the drive and ask for the correct drive.

The same issue might surface with the SoU XP1 cd, but I haven't tested this.

emerge --info 
Portage 2.1.8.3 (default/linux/x86/10.0, gcc-4.3.4, glibc-2.10.1-r1, 2.6.32-gentoo-r7 i686)
=================================================================
System uname: Linux-2.6.32-gentoo-r7-i686-Mobile_AMD_Sempron-tm-_Processor_2800+-with-gentoo-1.12.13
Timestamp of tree: Fri, 07 May 2010 16:00:01 +0000
distcc 3.1 i686-pc-linux-gnu [enabled]
app-shells/bash:     4.0_p37
dev-java/java-config: 2.1.10
dev-lang/python:     2.6.4-r1, 3.1.2-r1
dev-python/pycrypto: 2.1.0_beta1
dev-util/cmake:      2.6.4-r3
sys-apps/baselayout: 1.12.13
sys-apps/sandbox:    1.6-r2
sys-devel/autoconf:  2.13, 2.65
sys-devel/automake:  1.9.6-r3, 1.10.3, 1.11.1
sys-devel/binutils:  2.20.1
sys-devel/gcc:       4.3.4
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.6b
virtual/os-headers:  2.6.30-r1
ACCEPT_KEYWORDS="x86"
ACCEPT_LICENSE="* -@EULA"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=athlon-xp -O2 -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb /var/spool/torque"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=athlon-xp -O2 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests collision-protect distcc distlocks fixpackages news nostrip parallel-fetch protect-owned sandbox sfperms strict test test-fail-continue unmerge-logs unmerge-orphans userfetch userpriv"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LDFLAGS="-Wl,-O1,--as-needed"
MAKEOPTS="-j1"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="7zip X acl acpi alsa avahi berkdb bzip2 cairo cli cracklib crypt cxx dbus dri encode fam ffmpeg flac fortran fts3 gdbm gmp gnutls gpm gtk hal iconv icu ipv6 ithreads java5 jpeg libnotify mmx modules mudflap ncurses nls nptl nptlonly ogg openexr opengl openmp pam pcre perl pic player png pppd python rdesktop readline reflection sdl session sockets spl sqlite sqlite3 sse sse2 ssl startup-notification svg sysfs tcpd theora threads truetype unicode vnc vorbis x86 xcb xcomposite xorg zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="radeonhd" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" 
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Denis Dupeyron (RETIRED) gentoo-dev 2012-12-15 17:13:26 UTC
Thanks for the idea.

Unfortunately this is almost impossible to do since the file lists were gathered over many years. Whenever NWN was released in a different package we would simply add the necessary code to the ebuild. The information would come from developers (some of the retired), or in bugs here, in emails straight to us, etc... There are a few editions which are only available in some countries and/or in small volumes, so I'm not even sure we can recover them all now.

To implement this would require going back to these people and asking them to provide checksums. It would be a huge effort even if we knew how to contact them all. Also it seems this happened because you inserted the XP2 CD first instead of CD1. So, usually it shouldn't happen if you follow instructions.

I'm going to close this bug RESOLVED WONFIX. Feel free to reopen if you think this isn't right or if you have a patch.

Thanks,
Denis.