Originally posted by gradinaruvasile
View Post
The "normal non-distro-specific solution" is to clone the repo, configure, make and make install.
Note that i approach this from Debian/Ubuntu point of view since its easier to build deb files and track them, especially if certain compile options are changed which result in added/removed files from the build (the removed files' old version will still be there if you just use make install and may create problems).
But in case your repo has (and probably it has) a mesa installed from packages you have to make sure that the new libraries are loaded which can be tricky if there are 2 libraries in the library path (even if in different locations).
You have 2 choices:
-Install in a different prefix and convince ldconfig to always load the new libraries. Cleaner solution but i had some issues with old libs loaded.
-Overwrite the old libraries and deal with the package updating issues - if a new update appears for a mesa component and its upgraded, your libs will be overwritten since the apt system has no idea about what you did there.
Here you can do the following (i did it this way):
Compile mesa and make it a deb package - this package will step on many other system packages toes so to speak since Debian/Ubntu hacked mesa into a truckload of separate packages. Solution:
Find out what packages have conflicting files (trial and error, try to install the .deb file from terminal and watch the errors) and recreate the .deb, with the conflicting packages added to the "replaces" list until it will install. This will result in the built mesa's files added to a list in apt's records that state that the files in question belong to the newer package (mesa) and will not be bothered if the system's mesa library package is updated.
As for building for radeonsi, you only have to specify the "--with-gallium-drivers=radeonsi" config option. Example below my build script for r600 (i suppose replacing r60 with radeonsi would work):
Note that i use 64 bit system and i have to build mesa separately for 64 and 32 bit (the latter for 3d apps, mostly games that are 32 bit like for example the games from STEAM).
deb builder script:
Really really good idea to save these in scripts.
I also made a "master" script that pulls the latest gits, builds mesa, xf86-ati, glamor and creates+installs their .deb files in one shot.
Note that i approach this from Debian/Ubuntu point of view since its easier to build deb files and track them, especially if certain compile options are changed which result in added/removed files from the build (the removed files' old version will still be there if you just use make install and may create problems).
But in case your repo has (and probably it has) a mesa installed from packages you have to make sure that the new libraries are loaded which can be tricky if there are 2 libraries in the library path (even if in different locations).
You have 2 choices:
-Install in a different prefix and convince ldconfig to always load the new libraries. Cleaner solution but i had some issues with old libs loaded.
-Overwrite the old libraries and deal with the package updating issues - if a new update appears for a mesa component and its upgraded, your libs will be overwritten since the apt system has no idea about what you did there.
Here you can do the following (i did it this way):
Compile mesa and make it a deb package - this package will step on many other system packages toes so to speak since Debian/Ubntu hacked mesa into a truckload of separate packages. Solution:
Find out what packages have conflicting files (trial and error, try to install the .deb file from terminal and watch the errors) and recreate the .deb, with the conflicting packages added to the "replaces" list until it will install. This will result in the built mesa's files added to a list in apt's records that state that the files in question belong to the newer package (mesa) and will not be bothered if the system's mesa library package is updated.
As for building for radeonsi, you only have to specify the "--with-gallium-drivers=radeonsi" config option. Example below my build script for r600 (i suppose replacing r60 with radeonsi would work):
Code:
./autogen.sh --sysconfdir=/etc --prefix=/usr --libdir=/usr/lib/x86_64-linux-gnu --enable-debug \ CPPFLAGS="-m64" \ CXXFLAGS="-m64" \ --enable-64-bit --disable-32-bit \ --enable-texture-float \ --with-gallium-drivers=r600,swrast \ --with-dri-drivers="" \ --enable-vdpau \ --enable-egl --enable-gles1 --enable-gles2 \ --enable-glx-tls \ --with-egl-platforms=x11,drm \ --enable-gbm \ --enable-gallium-egl \ --enable-gallium-osmesa \ --with-osmesa-bits=32 \ --enable-gallium-llvm \ --enable-r600-llvm-compiler \ --enable-shared-glapi
deb builder script:
Code:
fakeroot checkinstall --install=no --replaces libgles1-mesa:amd64,libgl1-mesa-dev,libglapi-mesa:amd64,libgles2-mesa:amd64,libgbm1:amd64,libegl1-mesa-dev,libgl1-mesa-dri:i386,libgl1-mesa-dri:amd64,libgl1-mesa-glx:amd64,libegl1-mesa:amd64,libgl1-mesa-swx11:amd64,libegl1-mesa-drivers:amd64,libosmesa6-dev:amd64,mesa-common-dev --pkgname=mesa --pkgversion=`cat VERSION` --pkgarch=amd64 --backup=no
I also made a "master" script that pulls the latest gits, builds mesa, xf86-ati, glamor and creates+installs their .deb files in one shot.
Comment