OpenSDE Packages Database (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

141 lines
4.1 KiB

  1. # --- T2-COPYRIGHT-NOTE-BEGIN ---
  2. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  3. #
  4. # T2 SDE: package/.../iexplorer/iexplorer.conf
  5. # Copyright (C) 2006 The T2 SDE Project
  6. #
  7. # More information can be found in the files COPYING and README.
  8. #
  9. # This program is free software; you can redistribute it and/or modify
  10. # it under the terms of the GNU General Public License as published by
  11. # the Free Software Foundation; version 2 of the License. A copy of the
  12. # GNU General Public License can be found in the file COPYING.
  13. # --- T2-COPYRIGHT-NOTE-END ---
  14. autoextract=0
  15. makeopt=
  16. makeinstopt=
  17. datadir=$datadir/$pkg
  18. tmpdir=$builddir/tmp
  19. WINEPREFIX=$datadir/ie$ver
  20. SYSTEMDRIVE=$datadir/ie$ver/drive_c
  21. SYSTEMDIR=$datadir/ie$ver/drive_c/windows/system
  22. export WINEPREFIX SYSTEMDRIVE SYSTEMDIR
  23. PROGRAMFILES="Program Files" # detected after wineprefixcreate anyway
  24. hook_add premake 5 'do_basic_installation'
  25. do_basic_installation() {
  26. echo "Creating Wine Prefix"
  27. mkdir -p "$WINEPREFIX"
  28. xvfb-run -- strace -vvfF -o $WINEPREFIX/winreprefixcreate.strace wineprefixcreate
  29. touch $WINEPREFIX/.timestamp-base
  30. sleep 2
  31. PROGRAMFILES=$( ls -1 $SYSTEMDRIVE/ | grep -v windows | head -n 1 )
  32. # Install riched.dll
  33. echo "Installing RICHED20"
  34. cabextract -d "$tmpdir/" -F "ver1200.exe" `match_source_file -p 249973USA8`
  35. cabextract -d "$tmpdir/" -F "riched20.120" "$tmpdir/ver1200.exe"
  36. mv -v "$tmpdir/riched20.120" "$SYSTEMDIR/riched20.dll"
  37. # Install DCOM98
  38. echo "Installing DCOM98"
  39. cabextract -d "$SYSTEMDIR" `match_source_file -p DCOM98`
  40. mv -v "$SYSTEMDIR/dcom98.inf" "$SYSTEMDIR/../inf/"
  41. # Install mfc40
  42. echo "Installing ActiveX MFC40"
  43. cabextract -d "$tmpdir/" `match_source_file -p mfc40`
  44. cabextract -d "$tmpdir/" -F "mfc40.dll" "mfc40.exe"
  45. mv -v $tmpdir/mfc40.dll $SYSTEMDIR/
  46. # last things
  47. echo "And the icon"
  48. cp -v "$confdir/ie_wine.svg" "$docdir/ie_wine.svg"
  49. rm -rvf "$tmpdir/*"
  50. }
  51. hook_add postmake 5 'install_ie6'
  52. install_ie6() {
  53. echo "Extracting downloaded exe file"
  54. cd $tmpdir
  55. wine `match_source_file -p ie60`
  56. cd IE*
  57. mkdir -vp "$SYSTEMDRIVE/$PROGRAMFILES/Internet Explorer"
  58. echo "Extracting CAB files"
  59. cabextract IE_S*CAB
  60. cabextract -L -d $SYSTEMDIR/ IE_1.CAB IEDOM.CAB
  61. mv -v $SYSTEMDIR/{sch128c,schannel}.dll
  62. mv -v $SYSTEMDIR/iexplore.exe "$SYSTEMDRIVE/$PROGRAMFILES/Internet Explorer/IEXPLORE.EXE"
  63. cabextract -L -d $SYSTEMDIR SCR56EN.CAB
  64. cabextract -L -F "pngfilt.dll" ADVAUTH.CAB
  65. cabextract -L -F "msvcrt.dll" SETUPW95.CAB
  66. mv -v pngfilt.dll msvcrt.dll $SYSTEMDIR
  67. echo "Installing TTF Fonts"
  68. cabextract -L -F "*TTF" FONT*CAB
  69. mv -v *ttf $SYSTEMDIR/../fonts/
  70. echo "Configuring ie6"
  71. gunzip -c $confdir/winereg.system.reg.gz > $WINEPREFIX/system.reg
  72. gunzip -c $confdir/winereg.user.reg > $WINEPREFIX/user.reg
  73. cat <<-EOT > $bindir/ie6
  74. #!/bin/bash
  75. cd \$HOME
  76. export WINEPREFIX="$WINEPREFIX"
  77. exec wine "$SYSTEMDRIVE/$PROGRAMFILES/Internet Explorer/IEXPLORE.EXE" \$@
  78. EOT
  79. chmod +x $bindir/ie6
  80. cat <<-EOT > $docdir/ie6.desktop
  81. Exec "$bindir/ie6"
  82. Icon "$docdir/ie_wine.svg"
  83. Name "Internet Explorer $ver"
  84. GenericName "Microsoft Windows Aplication"
  85. Comment "Microsoft Internet Explorer on Linux"
  86. EOT
  87. rm -rvf "$tmpdir/*"
  88. }
  89. hook_add postmake 7 'install_flash'
  90. install_flash() {
  91. local OCXFILE=Flash8a.ocx
  92. echo "Preparing Flash Player 8"
  93. # Copy Flash files
  94. cabextract -d "$tmpdir/" `match_source_file -p swflash`
  95. # Create add.reg
  96. sed -n -e 's/^\[/;\[/g;/^;\[SW.AddReg\]/,/^;\[/p;' $tmpdir/swflash.inf > $tmpdir/add.reg
  97. sed -i '/^;/ d;/^\s/ d' add.reg
  98. strings=` sed -n -e 's/\s//g;s/^\[/;\[/g;/^;\[strings\]/,/^;\[/p;/^;/d;/^\s/d' swflash.inf `
  99. for string in $strings; do
  100. key=` echo $string | awk -F '=' '/^[^;]/ {print $1}' `
  101. value=` echo $string | awk -F '"' '/^[^;]/ {print $2}' | sed -e 's/\//BARRA/g '`
  102. sed -i -e "s/%${key}%/${value}/g;s/BARRA/\//g" add.reg
  103. done
  104. echo "Installing Flash Player 8"
  105. mkdir -p "$SYSTEMDIR/Macromed/Flash/"
  106. cp -v "$tmpdir/GetFlash.exe" "$tmpdir/$OCXFILE" "$SYSTEMDIR/Macromed/Flash/"
  107. wine regedit "$tmpdir/add.reg"
  108. wine regsvr32 'C:\Windows\System\Macromed\Flash\'$OCXFILE
  109. }