G H
G H

Reputation: 31

Compiling libnoise with a makefile

First, please note that I have seen this: How do I compile libnoise on Mac OS X Mountain Lio

I read it, but I did not get what it meant. I have never done anything like this before.

I am trying to get libnoise (http://libnoise.sourceforge.net/index.html) compiled to use it.
I have been following the instruction here: http://libnoise.sourceforge.net/tutorials/tutorial1.html under 'Using libnoise with gcc on UNIX platforms'.

I did this:

You've downloaded the libnoise headers (83 KB) into /usr/local/include/noise.

I had to create the '/include/noise' myself.

Then there is this:

You've built the binaries from the libnoise source (1,628 KB) and copied the resulting binaries into /usr/local/lib.

I'm not sure what to do at this point. I found the /noise/lib/Makefile inside of it. There is also a 'Makefile' in /noise and /noise/src. I used the first. Following what was said in the post mentioned above, I did this ./Makefile make all (I really don't understand what I am doing here), which resulted in this:

MyComputer:lib ghmacbook$ ./Makefile make all
: command not found 
./Makefile: line 3: .PHONY:: command not found
./Makefile: line 4: all:: command not found
./Makefile: line 5: -cp: command not found
: command not found 
: command not found clean:
./Makefile: line 8: -rm: command not found

In case it would help, here are the contents of the Makefile:

VPATH=../src/

.PHONY: all clean
all: libnoise.a libnoise.la libnoise.so.0.3
    -cp $? .

clean:
    -rm libnoise.*

I am most likely doing everything wrong. Can someone guide me on how to do this?

Upvotes: 1

Views: 395

Answers (1)

Kahin
Kahin

Reputation: 475

I know I'm really late with this answer and don't know if you have fixed the problem but I'll post this for people who will have problem with this in the future! I use a Macbook Air 13"

I found this:

git clone https://github.com/qknight/libnoise
cd libnoise
mkdir build
cd build
cmake ..
make
sudo make install

From: http://mineserver.be/wiki/Installation And tried it, and if you look at /usr/local/lib you will see libnoise.a and libnoise.dylib there! And also make sure that you have the noise folder with all the headers files in /usr/local/include

And when all this is done, make sure that you have the the noiseutils library sources, they can be found there: http://libnoise.sourceforge.net/downloads/index.html The .cpp file has to be included in your project. I used a separate main.cpp file to generate a .bmp file and them used that .bmp file as texture in my project.

Hope this helps the people having problem with this like I did!

Regards Kahin

Upvotes: 1

Related Questions