We already have a draft of a guide for SDK usage, hopefully it should appear in our docs soon.
I’m not sure if I understand you correctly, but the of package name is constructed as $(PKG_NAME)_$(PKG_VERSION)-$(PKG_RELEASE). If you add a patch or change the build process somehow, you should just bump the PKG_RELEASE. You can find more information about creating packages in the official OpenWrt wiki.
Also, xl2tpd is maintained in the upstream packages repository, so if you want to make it available for other users, you should submit a PR to the openwrt/packages GH repository.
I was able to compile xl2tp with my patch and PKG_RELEASE=3. (All dependences was satisfied)
I have created my own repo with this package, but I’m unable to sign it with my pub key. When I try to verify signed Packages file I get:
root@turris:/tmp# signify -V -P /etc/opkg/keys/ -x Packages.gz.sig -m Packages.gz
OK
root@turris:/tmp# opkg-key verify Packages.gz.sig Packages.gz || echo error
error
@sairon
My xl2tpd - devel-20151125-3 package is installed via my repository (signed) but it is automatically replaced after some hours by xl2tpd - devel-20151125-2 from turris repository.
How to prohibit openwrt from removing my package?
Does that mean that you got you verification working?
If so I suspect that you added your repository just as another feed for opkg. But this is not read by updater. So updater knows only one version and installs that version (if you are interested in why it doest this I wrote post about it here on forum some time ago: Updater is removing local packages - #17 by cynerd - SW bugs discussion - Turris forum).
Anyway when you want to use additional repository with updater, you must add that repository to updater configuration. See Sign in · GitLab