I am trying to keep version control of my own firmware in my dotfiles, and the way i wanted to do that was to symlink the dotfile-folder into the firmware folder, so qmk_firmware/keyboards/preonic/keymaps/c0dk points to dotfiles/qmk_keyboard..
However make preonic/rev3:c0dk returns make[1]: *** No rule to make target 'cabang'. Stop. - which is naturally because it doesn't follow symlinks...
Not sure if this would be a new feature or a bug..
But it could help fix https://github.com/qmk/qmk_firmware/issues/1120 - because i can then keep the firmware repo with non-checked-out files, and simply use a VCS on my own folder.. but I need maketo follow symlinks.. which it doesn't.
This worked fine for me:
(from ~/qmk_firmware)
cp -r keyboards/atreus/keymaps/ridingqwerty ~/ridingqwerty
rm -rf keyboards/atreus/keymaps/ridingqwerty
ln -s ~/ridingqwerty keyboards/atreus/keymaps/ridingqwerty
make atreus:ridingqwerty
What's jumping out to me here is that the keymap name is cd0k, but make chokes on rule to make cabang -- what is that a reference to?
oops sorry it's because I call it "cabang" but wanted to change it to make it obvious that i was my username. I'll try again i guess.
I think as long as the symlink is sound, e.g. the target and destination names match, represent the named <keymap> directory, and relevant keymap structure is there, it should be fine.
You were right. i think i placed the symlink the wrong place. it works now! thanks!
Awesome!
This is not working for me. Could any of you confirm if this still works or if something has changed in the build process in the meantime?
The procedure I used here still works for me (I amended it slightly to make the rm more explicit after copying the keymap out of tree).
What exactly are you doing?
This is what happens to me if I follow your instructions:
> cd /tmp
> git clone [email protected]:qmk/qmk_firmware.git
Cloning into 'qmk_firmware'...
remote: Enumerating objects: 4, done.
remote: Counting objects: 100% (4/4), done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 221551 (delta 1), reused 1 (delta 1), pack-reused 221547
Receiving objects: 100% (221551/221551), 148.22 MiB | 14.87 MiB/s, done.
Resolving deltas: 100% (139623/139623), done.
> cd qmk_firmware
> cp -r keyboards/atreus/keymaps/ridingqwerty ~/ridingqwerty; \
rm -rf keyboards/atreus/keymaps/ridingqwerty; \
ln -s ~/ridingqwerty keyboards/atreus/keymaps/ridingqwerty
> ll keyboards/atreus/keymaps/ridingqwerty
lrwxrwxrwx 1 andre users 24 Oct 21 16:28 keyboards/atreus/keymaps/ridingqwerty -> /home/andre/ridingqwerty
> make git-submodule
...
> make atreus:ridingqwerty
QMK Firmware 0.10.41
WARNING:
Can not run bin/qmk! This tool will be required when the develop branch is merged on 2020 Aug 29.
Please run util/qmk_install.sh to install all the dependencies QMK requires.
Making atreus/astar with keymap clash and target ridingqwerty [ERRORS]
make[1]: *** No rule to make target 'ridingqwerty'. Stop.
Making atreus/astar with keymap classic and target ridingqwerty [ERRORS]
make[1]: *** No rule to make target 'ridingqwerty'. Stop.
Making atreus/astar with keymap default and target ridingqwerty [ERRORS]
make[1]: *** No rule to make target 'ridingqwerty'. Stop.
...
The only way it works for me is if I create the folder and instead symlink all the files inside it (which is a bit less pratical than just symlinking the folder).
Can you make anything else? What does this do?
make planck/rev6:default
(just saw your update so I'll assume this works)
โฏ make planck/rev6:default
QMK Firmware 0.10.41
WARNING:
Can not run bin/qmk! This tool will be required when the develop branch is merged on 2020 Aug 29.
Please run util/qmk_install.sh to install all the dependencies QMK requires.
Making planck/rev6 with keymap default
arm-none-eabi-gcc (GNU Tools for Arm Embedded Processors 9-2019-q4-major) 9.2.1 20191025 (release) [ARM/arm-9-branch revision 277599]
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Compiling: quantum/audio/muse.c [OK]
Compiling: keyboards/planck/planck.c [OK]
Compiling: keyboards/planck/rev6/rev6.c [OK]
...
I wonder if this is something to do with the group ownership of /tmp being root. In my example everything in qmk_firmware and ~ is owned by my user.
My initial tests were done in my home, I only cloned to /tmp to show the full setup. Are you using Linux?
Yeah I'm on Ubuntu 18.04
I believe it was caused by this bug https://savannah.gnu.org/bugs/?func=detailitem&item_id=53465. I was using GNU Make 4.2.1, with 4.3 it works. Thank you for your help :)
Most helpful comment
You were right. i think i placed the symlink the wrong place. it works now! thanks!