SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Apparently, when the source tarball is untarred in line 37, the resulting directory is not called l2tp-ipsec-vpn-client_1.0.9. Try untarring it yourself from the command line to find out the name of the resulting directory.
The naming convention in the original SlackBuild is a common one that is seen when extracting source. Most of the time, it will be the program name with a dash, then the version, so $PRGNAM-$VERSION usually works. However, not all projects use that naming convention, so sometimes you need to handle it differently in the SlackBuild. In this case, montagdude is correct, you can just simply use cd $PRGNAM to enter the directory. Make sure you update the rm section as well (two lines above), so it can clear out the old folder before it tries extracting again.
There are other times when the source folder is named completely different, or the version might be incompatible with Slackware standards (maybe it has a dash in the version) or maybe it is really long (if you're using a git commit). In those cases, you can either hardcode the values or use different variables (the latter is my personal choice). In those cases, I'll use $SRCNAM and/or $SRCVER, depending on what is needed.
This is because there is no configure file in the source archive. Type "make help" to know the options, and see in https://sourceforge.net/projects/l2t...sec-vpn/1.0.9/ the prerequisites and installation instructions. In this case a SlackBuild template can't be used as is but needs an adaptation as autotools is not used by upstream.
Before or while in the process of creating a SlackBuild script, it's a good idea to build the software manually first. Read any included documentation, like the README and INSTALL files, to see what the authors say about how to build it. Then, once you have a good handle on the process and have built it successfully by just entering the commands on the command line, you can capture the steps in the SlackBuild script. As you are finding, the templates often need adjustment to work with different software. They're not meant to be automatic for the person creating the script.
Also, if you post a link to the source code you are working with, I'm sure people would be able to help you better. I did a quick search but didn't find it.
Edit: actually, on that last point, it looks like Didier found it already. I'll have a look later if I get the chance.
Last edited by montagdude; 05-24-2017 at 05:53 PM.
This is because there is no configure file in the source archive. Type "make help" to know the options, and see in https://sourceforge.net/projects/l2t...sec-vpn/1.0.9/ the prerequisites and installation instructions. In this case a SlackBuild template can't be used as is but needs an adaptation as autotools is not used by upstream.
I looked at what's in the tarball, and unfortunately in this case there isn't any documentation other than what's on the Sourceforge page and `make help` as Didier suggested. It looks like the basic build process will be something like:
Code:
make
make INSTALL_ROOT=$PKG
(While you are testing from the command line, you might want to instead make a local directory to set as INSTALL_ROOT.) From the list of requirements on Sourceforge, it appears that you will need to have ctemplate and cppunit installed from SBo. The rest should be already in Slackware, except I'm not sure about libengine-pkcs11-openssl. Good luck!
Last edited by montagdude; 05-25-2017 at 09:06 AM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.