# Png23d & Stlcmd



## grumps (Aug 25, 2022)

I am a retired and very tired old man with all the disabilities age brings, teetering on the edge of dementia and looking for some help on getting a couple of scripts transferred from deb to pkg. It took me a goodly few days to get my Anir mouse to operate correctly and convert my old python and bash scripts transferred but I am buggered if I can get this to work 
https://github.com/AllwineDesigns/stl_cmd 
and this one 
https://github.com/kyllikki/png23d 
any help would be greatly appreciated tia.


----------



## Jose (Aug 25, 2022)

grumps said:


> https://github.com/AllwineDesigns/stl_cmd


Install devel/gmake:

```
pkg install gmake
```
Use `gmake` instead of `make`, and add `CC=c++` to the command line. E.g.

```
gmake install CC=c++ # will install to /usr/local/bin by default
```


----------



## Jose (Aug 25, 2022)

grumps said:


> and this one
> https://github.com/kyllikki/png23d


This one's a little harder. You still need devel/gmake, but you'll also have to add `#include <unistd.h>` near the top of bitmap.c. Then you'll be able to build it like this

```
gmake OPTFLAGS=-I/usr/local/include LDFLAGS="-L/usr/local/lib -lpng"
```


----------



## grumps (Aug 26, 2022)

Thank you so much, I really appreciate the assistance.
The stlcmd was my own stupid fault. While I had read the readme file and was entering the commands correctly I was wrongly doing it in the "src" folder where there is no makefile. I now have it working as it should after linking the many scripts.
The png23d though is a different matter, following your instruction it did indeed succesfully build and create an executable, however the results are empty files so something is still not working in there.

Edit:
Ignore me the error is once again mine, I tried to replicate the error message to post here and could plainly see the scripted command was wrong, all is good and thanks again for your valuable help.

Next question: Can you recommend a remaster tool? In Debian I simply type "bootcdwrite" and it would create a iso of my complete system but I don't know of one for FreeBSD.


----------



## Jose (Aug 27, 2022)

grumps said:


> Next question: Can you recommend a remaster tool? In Debian I simply type "bootcdwrite" and it would create a iso of my complete system but I don't know of one for FreeBSD.


I got nothin'. Never heard of that, and it's pretty freakin' cool.


----------



## grumps (Aug 27, 2022)

Well here's the current working tar from my Debian system if you fancy having a play with it. It creates an iso file in /var/spool/bootcd/ 
I had to rename the upload to .zip in order to ping it through, change the zip to xz for unpacking. 


			Debian -- Details of package bootcd in buster
		

It would be good if somebody could make it work for FreeBSD and port it to pkg as it is a useful tool.
Being an old school admin I work as root all the time so it's very handy to have a restore point burned to flashdrive.

Have a great day, stay safe and make time for what you enjoy.


----------

