Giter Club home page Giter Club logo

tpdualscan's Introduction

ThinkPad Dual Scan VRAM fix

tpdualscan.c (also known as tpdscan.c) was originally written by Michael Steiner in the 90s. I've committed it to this repository so it can be found using Google.

As written by Debian developer Ben Hutchings in 2015: "gcc for i386 has recently been changed to target 686-class processors and is generating code that will crash on other processors". LLVM is also not supporting i486, since it assumes at least the (original) Pentium. Although this might change in the future. Using an older gcc release is the only feasable option at the moment.

Compilation

Compiling an old gcc using a new version of gcc does not seem to be a good idea.That's why I tried using an old Ubuntu release which had the old version still packaged.

Open an Ubuntu 12.04 ISO and run the virtual machine. Replace the apt subdomain in sources.list with old-releases and install gcc and gcc-multiplib. Note that the gcc multilib version and gcc needs to be equal.

Links

Old

Compilation instructions

It is needed to apply some patches to gcc 4.8.2 so it can be built using gcc 9.3.0... ๐Ÿ™ƒ

git clone https://github.com/eloydegen/tpdualscan
cd tpdualscan
sudo apt install build-essential
https://ftp.gnu.org/gnu/gcc/gcc-4.8.2/gcc-4.8.2.tar.bz2
tar xvf gcc-4.8.2.tar.bz
cd gcc-4.8.2
./contrib/download_prerequisites
./configure
wget https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff_plain;h=ec1cc0263f156f70693a62cf17b254a0029f4852 build.patch
patch -p1 < build.patch 
wget https://gcc.gnu.org/git/?p=gcc.git;a=patch;h=883312dc79806f513275b72502231c751c14ff72 build2.patch
patch -p1 < build2.patch 
make
./bin/gcc -march=i486 ./tpdualscan.c -o tpdualscan

Also apply these patches:

tpdualscan's People

Contributors

eloydegen avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.