-
Notifications
You must be signed in to change notification settings - Fork 0
Setup

This set up tutorial is specifically for Visual Studio. if you are using a Different IDE search "How to consume a static library in [Your IDE Here]"
There are two methods to adding NStrings to your project, if one doesn't work try the other, if they both don't work make a issue and I can assist😸
Pros and Cons of each method
| Method # | Pro | Con |
|---|---|---|
| Method 1 | Faster and more concise | Requires manual upgrading |
| Method 2 | Will automatically update if you replace the .h and .lib while keeping names and locations the same | Can be seen as confusing or harder to do |
You can download older versions if you'd like but this walkthrough is meant for setting up v0.1.0-Beta and onward All versions older than v0.1.0-beta have been deprecated as of 24/5/24
Unzip the release package downloaded from step one. While the place you save it doesn't particularly matter it is recommend that its folder is in the same directory as your project folder.

(In the image both directories are in ..\Desktop\Demo)
Or start a new one. The process is the same either way.
To do this right click the top node of your project in your solution explorer and under "Add" click "Existing Item" (Shown Below)

Then in the file window navigate to the directory that contains NString_Static.lib and click "Add"

This step will vary depending on how you set up your directories but using the setup shown in step 2 the line to include the .h file will be
#include "..\NStrings\nstring.h"
You can download older versions if you'd like but this walkthrough is meant for setting up v0.1.0-Beta and onward All versions older than v0.1.0-beta have been deprecated as of 24/5/24
Unzip the release package downloaded from step one. While the place you save it doesn't particularly matter it is recommend that its folder is in the same directory as your project folder.

(In the image both directories are in ..\Desktop\Demo)
While this is not all that necessary for this method of installation it still makes it helpful
Or start a new one. The process is the same either way.
You can do this by hitting Alt+Enter or right clicking on the top node of your solution and clicking properties.

To do this go to the "Linker" tab on the left side menu and select "Input"

In the large box on the right locate the line named "Additional Dependencies" which should be at the top and look like the attached image

At the front of the list in the right most field add the file path to NString_Static.lib followed by a semi-colon
This Step will vary depending on where you save NStrings, the file path in the image would work given the example in step 2

This step will vary depending on how you set up your directories but using the setup shown in step 2 the line to include the .h file will be
#include "..\NStrings\nstring.h"
Now you can use nstrings in your project! 😸
Revisions underway
This project is still in very early stages. Documentation will be updated with code to the best of my ability.