9

I'm a long time Fedora BFU and decided to switch to Debian for my new Dell XPS. Unfortunately, on a fresh install, I only get to work with a microscopic CLI and no internet connection, as both GPU and network card seem to need additional drivers to work. I found both drivers online, but I'm failing to install them.

GPU driver needs cc in $PATH, but I think I'm missing GCC alltogether:

gcc # command not found, 
man gcc # no manual entry for gcc

With Realtek, I cannot make the installer: make # make: command not found

I'm a bit surprised that I don't get gcc and make out of the box - is there an easy way to install some bundle multiple of these basic apps from a USB drive?

mkurz
  • 197
  • 1
  • 6
  • try this (although the question is about MX linux, that just seems to be a variant of old debian, so the answer applies to your debian): https://unix.stackexchange.com/questions/654020/installing-packages-from-usb-to-offline-mx-linux-system/654037#654037 – Marcus Müller Jun 20 '21 at 21:05
  • 1
  • Using another connection, download the packages to USB and use dpkg -i somename.deb Within recent years downstream distributions broke Network Manager and this was the solution at the time. Note the dependencies such as gpp too. – mckenzm Jun 22 '21 at 03:21
  • Just USB-tether via your smartphone, and then install the needed packages to get the onboard network card working. Or is there a detail in your situation, that makes this impossible? If so, please edit it into your question. – Alex Stragies Jun 22 '21 at 17:36
  • @AlexStragies Unfortunately I don't have an appropriate cable - laptop only has USB-C and my smartphone uses microusb... but wouldn't that still fail without network card drivers? – mkurz Jun 22 '21 at 18:52
  • All major OSs have had drivers for USB network tethering with standard smartphones since many years. Just pick up a USBC-to-microUSB adapter for a few pennies. That'll also reduce the number of cables you need to lug around. And you can probably avoid compiling things if you just install the 5.1X kernel from debian backports – Alex Stragies Jun 22 '21 at 20:17
  • @AlexStragies Yeah, you're right. I'll get a chance to buy the cable on thursday, I will do that. I managed to solve the issue with help from Stephen Kitt btw (although other arose). – mkurz Jun 22 '21 at 20:24

2 Answers2

20

In your situation, I would install using the unofficial, firmware-included full DVD (which can also be used on a USB stick). While labelled as “unofficial” this is still prepared by the same people who prepare the official installation images, and it has two advantages in your specific use-case:

  • it includes firmware and non-free drivers, possibly including those you need for your hardware;
  • it also includes GCC, Make etc., so you can install them directly.

GCC and Make aren’t installed by default; to install them from the installation image, ensure your /etc/apt/sources.list file still has the

deb cdrom:[Debian GNU/Linux 10.10.0 _Buster_ - Unofficial amd64 DVD Binary-1 with firmware 20210619-16:16]/ buster contrib main non-free

entry (as set up by the installer — the exact timestamp might vary), mount the DVD image, and run

apt install gcc make

as root.

(If you want to give Debian 11 a shot, the equivalent image is also available, using RC2 of the installer. This has a newer kernel than the Debian 10 setup, and may work better on your new hardware.)

If you don’t need non-free firmware, but would like to be able to install GCC and Make from the installation media rather than from Internet mirrors, you can use the official DVD images instead (only the first DVD is needed).

Stephen Kitt
  • 434,908
0

Or you can use this without restarting, without grinding for help or etc. and it works for others! I tested it and it works! To install make and cmake, use: (only onto /home/(user)

mkdir bin

And enter to bin using cd bin Then on what you'll do is:

apt-get download make

This will download make and next is:

dpkg-deb -x make_(version)_(cpu_insturtructure_idk_what_to_call_it).deb /home/(user)/bin

This will extract whatever is on here

WARNING this may get complicated for sh or bash users so for sh:nano ~/.bashsrc and bash: nano ~/.bashrc and go the bottom and modify at the end.

So for me, I would personally recommend you using bash not sh cause my pc is on sh, you can use the command bash to enter to bash.

We gotta edit the .bashrc file so we need to enter:

nano ~/.bashrc

It is non-root so it will work then we gotta add this at the end:

export PATH="/home/(user)/bin/make_(version)_(cpu_insturtructure_idk_what_to_call_it)/usr/bin:$PATH"

Then save it.

When you're done, you can execute this command:

source ~/.bashrc

And voilà! It will work easily!

You can also do that with gcc BUT in a separate file if you could find the bin file under usr file.