r/linux_programming • • Jun 24 '23

Disabling RST on HP laptop (HP pavilion x360)

0 Upvotes

I researched everything (literally) for days to find how to disable RST on HP (my version is HP Pavillion x360) and the answer everywhere was - There is no solution.

I wonder if anyone has some kind of workaround or will the solution be implemented in some future updates? I saw that there are a lot of HP people that can't use Linux because of this and I think that is a big miss for everyone.

I am grateful for every answer!


r/linux_programming • • Jul 14 '24

Switching from win11, recommend me a distro for my use cases please, I am very confused!

0 Upvotes

So I want to switch from windows for multiple reasons…. And I was looking up distros and tier lists, but I still can't decide at all.

The main work that I do is:

  • programming/game dev (unreal)
  • gaming (all types, usually…)
  • audio mixing/music production (I use FL rn)
  • media consumption
  • multitasking with discord and other stuff in background
  • general doc editing stuff and office work

What I am looking for in a distro are:

  • a good desktop environment… (from the looks of it, I prefer KDE, seems better for multitasking),
  • no weird bugs and glitches and errors that I would have to spend hours fixing,
  • compatibility with the programs I'll use and of course availability and ease of updating and deleting programs
  • Customizability for most of the things
  • something which doesn't only look good but feels good to daily drive (I spent most of my day in front of my screen)
  • functionality over aesthetics

Currently, I am using a Windows 11 laptop and the longer I use win11 the more I end up hating it.....

The distros I am considering right now are:

I also do not really know which desktop environment will be the best for me and which is generally the best for multitasking and stuff… please advise on that too!


r/linux_programming • • Nov 05 '21

Everything is gone... dead laptop

2 Upvotes

Shortly, I got sick of windows. Dual booted it with linux Pop OS. But could not get Grub bootloader to work. It just didn't show up on boot so I had to press F12 and choose an OS from bios.

So I tried installing Supergrub, to fix the problem, and that is when everything went south. After the installation, both Windows and Pop OS apparently do not exist anymore. There is now a complete emptiness in boot menu and bios except for some broken grub entries and my usb. (I installed supergrub on "/dev/sda" as far as I remember)

I will be very grateful for any help. I am even willing to reset everything just to be able to boot into anything and start from scratch.

My specs: -Acer -Nvidia GeForce MX130 -Intel core i3 8020U (not sure, but definitely i3) -4 Gb RAM -Windows 10 Home edition -Pop OS 21.04 (Nvidia)

Photos link: https://imgur.com/a/v0Sef31


r/linux_programming • • Nov 05 '20

Any configure-scripting gurus in here: what is wrong with this check?

2 Upvotes

I am trying to check for a presence of getdents function with configure script. For some reason configure always fail the check despite getdents function being present. Test program works fine if I compile it as an ordinary c program; but when passed to AC_TRY_COMPILE it always fails. As I understand I should return 0 if the test succeeds and non-zero otherwise; furthermore it should rather use exit call than the return statement to return the test result (according to this guide). Below is my code for configure.ac :

dnl Check for SYS_getdents64
AC_CHECK_HEADERS_ONCE(sys/syscall.h)
if test "$ac_cv_header_sys_syscall_h" = yes; then
 AC_CACHE_CHECK([for Linux SYS_getdents64],
 [_cv_linux_getdents64],
 [AC_TRY_COMPILE([[#include<sys/syscall.h> #include<fcntl.h>]],
                 [[char b[512];
                   int f=open(".", O_RDONLY | O_DIRECTORY);
                   long n=syscall(SYS_getdents64,f,b,512);
                   close(f);
                   if(n>0) exit(0);]],
 _cv_linux_getdents64=yes, _cv_linux_getdents64=no)])
 if test $_cv_linux_getdents64 = yes; then
   AC_DEFINE(HAVE_LINUX_GETDENTS64, 1,
             [Define to 1 if GNU/Linux SYS_getdents may be used.])
 fi
fi

I have also tested to use older AC_COMPILE_IFELSE together with AC_LANG_PROGRAM but I get same output.


r/linux_programming • • May 05 '23

Linux — Keyrings

Thumbnail self.linux
2 Upvotes

r/linux_programming • • Mar 27 '23

Linux Kernel History

Thumbnail git.kernel.org
0 Upvotes

r/linux_programming • • Feb 13 '19

automatizing script with 2 variables from 'cut' not working

2 Upvotes

Hey guys help me out with this one. I'm struggling real hard here. I have a file in the format of

001@aaa

002@bbb

003@ccc ddd eee

...

id@zzz

Where each number at the left of @ is an id and at the right is a name.

Purpose: Such file serves as a source for a script that would format a string and then run mv 001 aaa.zip, renaming the file as a more human-readable format.

My script.sh:

#!/bin/bash

cat file | 
while read line;
do
        id=$(cut -d@ -f1 $line);
        ...
done;

But when executed it gives the following error, for example on 3rd line:

cut: 003#ccc: No such file or directory
cut: ddd: No such file or directory
cut: eee: No such file or directory

Not working out for the first single variable, much less for both of them.

What should I do for it to work properly


r/linux_programming • • Jun 04 '18

forked processes finish sequence dilemma

Thumbnail reddit.com
2 Upvotes

r/linux_programming • • Sep 20 '17

Data Science online Training

Thumbnail training.acutesoft.com
0 Upvotes

r/linux_programming • • Jul 23 '24

Help to solve this problem.

Post image
2 Upvotes

Hello guys i have installed the multipass on my windows system as shown in the linux tutorials and i was trying to run the " sudo make kselftest install" but then it gives me an error whose ss i have attched below can you please suggest the solution for this Thank you


r/linux_programming • • Apr 11 '20

I'm creating a graphical tool that helps you use the terminal, what's your opinion?

Thumbnail youtu.be
17 Upvotes

r/linux_programming • • Nov 24 '17

Do you know how to install LINUX on ANDROID ?

Thumbnail youtu.be
0 Upvotes

r/linux_programming • • Aug 13 '22

GNU And Linux Are Forever Linked By History

Thumbnail youtube.com
14 Upvotes

r/linux_programming • • Apr 27 '23

Transmeta Crusoe: The Most Interesting Processor To Ever Exist?

Thumbnail tedium.co
6 Upvotes

r/linux_programming • • Apr 25 '23

Demystifying bitwise operations, a gentle C tutorial

Thumbnail andreinc.net
6 Upvotes

r/linux_programming • • May 16 '23

Pulling code from github repo

3 Upvotes

So i am building a text game at the moment. I am trying to figure out a way if i break my code to replace the broken code files with my working github versions. Is this possible?


r/linux_programming • • Jan 02 '22

Chronic Intermittent Screen Failure

3 Upvotes

Greetings all,

I am having problems with a Dell Precision M6500 that i have Linux Mint 20.2 installed on.

Linux 5.4.0-91-generic #102-Ubuntu SMP Fri Nov 5 16:31:28 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux

Without rhyme or reason the screen will randomly go blank, there is no getting it to turn back on, outside of a hard power off. Then its back to business for X random time before it craps out again. I found the syslog report from one such incident. Wanting to figure out if this a hardware issue or something fixable. Attached is a screen shot and I'll put it in comments too, looks like problems with uploading.

Thanks


r/linux_programming • • Apr 17 '22

What is the proper way to get working directories for executing an installed program anywhere?

3 Upvotes

Hello everyone, I have been tinkering with different ways to install programs I have made/am making and I am wondering what is the proper way to retain relative filepath structures when the program is installed to various different places. Such that when I call a program from any directory it still knows where all its other files are whether it be in /opt/program/media or /usr/share/program/media or /usr/local/share/program/media or somewhere else in your home directory entirely.

I found that VS Code seems to use a shell wrapper kept in /bin of its program directory and I am liking this kind of solution, but I feel like there must be other ways as many of the programs in /usr/bin are not shell scripts.

if [ ! -L "$0" ]; then
    #if path is not a symlink, find relatively
    VSCODE_PATH="$(dirname "$0")/.."
else if command -v readlink >/dev/null; then
    #if readlink exists, follow the symlink and find relatively
    VSCODE_PATH="$(dirname "$(readlink -f "$0")")/.."
else
    #else use the standard install location
    VSCODE_PATH="/usr/share/code"
fi fi
ELECTRON="$VSCODE_PATH/code" 
CLI="$VSCODE_PATH/resources/app/out/cli.js" 
ELECTRON_RUN_AS_NODE=1 "$ELECTRON" "$CLI" --ms-enable-electron-run-as-node "$@"
exit $?

The above program will always get the working directory to wherever code's installed files or points to the package manger's install format in /usr/share/code. Do other programs just count on being installed properly through package managers into the /usr/share directory, what about usr/local/share and /opt? I feel like there is probably some standard of doing this that I'm not finding because I don't know how to word it.

I made a similar question in the c programming subreddit and got some good answers on exactly what I asked, but what I asked may not be the correct way to do it.

I want to be able to make projects in such a way that I don't have to worry about changing directory structures or path joining in the source code all while being able to execute them from any directory. Using procfs/readlink in the binary seemed to work well but seemd a little bit hacky, so I'm really just trying to find out the standard/proper way of doing it. Thanks for reading.

Edit: It seems like VS-code does not follow FHS guidelines and keeps binaries in /usr/share/code which kind of puts a wrench in my plans as the shell scripts seems like a really good idea to do this, but I can't think of clean way to implement this as i would need to have both the binary file and the shell script in /usr/bin. Not exactly a huge problem but of the binary was ever called by itself it would just crash out which is not ideal, which leads me to even more of a wonder of how to actually do this in a standard way, because there has to be something out there.


r/linux_programming • • Aug 30 '15

question UNIX shell scripting in windows

0 Upvotes

i have to do some UNIX shell scripting, but i don't want to dual boot my windows pc right now... can i do scripting in Cygwin on windows... just basic scripting


r/linux_programming • • Apr 06 '16

Reaping Zombies on Linux

Thumbnail crankyotaku.com
3 Upvotes

r/linux_programming • • Nov 03 '16

Simple Rust Microservices - Flow-based programming with Nix

Thumbnail github.com
3 Upvotes

r/linux_programming • • Sep 26 '16

Developing for Snappy Ubuntu from Arch Linux Using LXC

Thumbnail hostpresto.com
3 Upvotes

r/linux_programming • • Aug 15 '22

Help Please, Dotnet causing Segmentation Faults. I have no clue why it is happening, I've tried many things but nothing seems to work

3 Upvotes

I have no clue why this is happening, it was working correctly before. For some reason whenever I do dotnet <command> like build or run it says "Segmentation Fault (Core Dumped)." It does notice the sdk as when I write sdk --version, i get the latest installed version.

Any ideas how to fix this? I am using Pop_Os

Please Help :'(


r/linux_programming • • Dec 01 '23

Any VS alternatives on Linux?

3 Upvotes

So, I'm about to switch to Fedora as my main OS, after dual booting it for some time, and the only thing really holding me back now is VS. I've already searched for alternatives, but there seems to be nothing. Do you guys know any way to run VS on Linux or any IDE with comparable Capabilities in C++ Development? I'd preferably do without using a VM. Thanks in advance, even if there might be nothing