Homebrew app Can't compile homebrew (hidKeysDown)

ThatBenderGuy

Well-Known Member
OP
Member
Joined
Dec 16, 2013
Messages
150
Trophies
0
Age
31
XP
348
Country
United States
I have recently installed Ubuntu and was setting up my development environment for DevKitPro. My project is to update a dead homebrew for personal use. I have installed all the switch libraries using dkp-pacman, and when I run make in the project's directory I get a bunch of errors but they all stem from the error:
source/main.c:501:33: error: 'CONTROLLER_P1_AUTO' undeclared (first use in this function) u64 kDown = hidKeysDown(CONTROLLER_P1_AUTO);
I have not programmed in C much but I assume due to changes in libraries since this the last time the homebrew was updated that CONTROLLER_P1_AUTO is deprecated now but I have no clue how to figure out what replaced it. The project does use SDL2 but it's not used in the main.c file (which is where this compile error is occuring). Any suggestions or ideas? I'm new to switch homebrew development but I really wanted to update this app because it's useful.

EDIT:
I also noticed I get these compile errors
warning: implicit declaration of function 'hidScanInput' [-Wimplicit-function-declaration]
warning: implicit declaration of function 'hidKeysDown' [-Wimplicit-function-declaration]
 

rash1613

Member
Newcomer
Joined
Apr 16, 2022
Messages
11
Trophies
0
Age
24
Location
New York
XP
114
Country
United States
I have recently installed Ubuntu and was setting up my development environment for DevKitPro. My project is to update a dead homebrew for personal use. I have installed all the switch libraries using dkp-pacman, and when I run make in the project's directory I get a bunch of errors but they all stem from the error:

I have not programmed in C much but I assume due to changes in libraries since this the last time the homebrew was updated that CONTROLLER_P1_AUTO is deprecated now but I have no clue how to figure out what replaced it. The project does use SDL2 but it's not used in the main.c file (which is where this compile error is occuring). Any suggestions or ideas? I'm new to switch homebrew development but I really wanted to update this app because it's useful.

EDIT:
I also noticed I get these compile errors
take a look at this example to see how button presses are read now
https://github.com/switchbrew/switch-examples/blob/master/hid/read-controls/source/main.c
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • K3Nv2 @ K3Nv2:
    Still don't know why he left unless someone really hurt his feelings
  • K3Nv2 @ K3Nv2:
    Don't know why people get so emotional online just get over it ffs
    +2
  • BigOnYa @ BigOnYa:
    He was the ass of gbatemp, everyone knocked on him, I honestly felt bad, even though I was guilty myself, but he egged it all on himself,
  • BigOnYa @ BigOnYa:
    But he still here, but under dif name, he pm me sometimes still even.
  • K3Nv2 @ K3Nv2:
    It's like they think we'll be in their bed pissing on it the next day
  • BigOnYa @ BigOnYa:
    I feel like gbatemp should make t-shirts or memorabilia to remember the lost ones. I bet the Polly shirts would sell out quick.
  • K3Nv2 @ K3Nv2:
    Nah that could actually bring lawsuits
  • K3Nv2 @ K3Nv2:
    Tempsuits
  • BigOnYa @ BigOnYa:
    PollySuits
  • BigOnYa @ BigOnYa:
    Your correct, Somebody would be guilty and there would be riots, then they storm the gbatemp capitol,
  • K3Nv2 @ K3Nv2:
    Online or not there are still certain rights that judges would have no issue handing out a warrant over
  • K3Nv2 @ K3Nv2:
    Just look at Kim dotcom
  • BigOnYa @ BigOnYa:
    Honestly I'm scared to, from you, but ok, lemme turn on vpn, virtual machine, private browser first
  • K3Nv2 @ K3Nv2:
    Remember that Alexa robot I gifted you
  • K3Nv2 @ K3Nv2:
    And that laptop Webcam you never tapped up
  • BigOnYa @ BigOnYa:
    That robot is here somewhere, I hear it moving around at night, but I haven't seen it for months.
  • BigOnYa @ BigOnYa:
    Oh that laptop I give to ancientboi, so you been watching him for months, and he's been watching you
  • K3Nv2 @ K3Nv2:
    Oh good more than enough material for the fbi
    +2
  • BigOnYa @ BigOnYa:
    Damn its 5 in morn, I gotta Go wake your mum and send her to work. Check ya later.
    +1
  • Psionic Roshambo @ Psionic Roshambo:
    He could make so much money!!! His arm would never get tired lol
    +2
  • S @ salazarcosplay:
    How are yall doing
    +1
    S @ salazarcosplay: How are yall doing +1