D
Deleted member 67440
Guest
I am new to ports (and pkg) development for FreeBSD.
I would like to know, please, if there is a complete example of a very simple "Hello world" port.
In fact, it is not very easy, at least at the beginning, to disentangle the numerous complications
(ex g ++ vs clang).
I found a lot of information about it but, almost always, related to extremely complex projects to compile, with very difficult configuration files, for a beginner at least.
Basically I have a project consisting of two .cpp (zpaq.cpp and libzpaq.cpp) files and one .h (libzpaq.h) that I would like to make available to the BSD world.
It is a fork of a compressor with deduplication, in my opinion the most advanced in the category.
So I would like to do the relative port first (in archivers) and then also the binary version, for pkg add.
The "make" is just like that
g++ -O3 -march=native -Dunix zpaq.cpp libzpaq.cpp -pthread -o zpaqfranz -static-libstdc++ -static-libgcc
or
clang++ -march=native -Dunix zpaq.cpp libzpaq.cpp -pthread -o zpaqfranz -static
Creating a single executable (zpaqfranz) to be putted into /usr/local/bin
Thanks for any reply
I would like to know, please, if there is a complete example of a very simple "Hello world" port.
In fact, it is not very easy, at least at the beginning, to disentangle the numerous complications
(ex g ++ vs clang).
I found a lot of information about it but, almost always, related to extremely complex projects to compile, with very difficult configuration files, for a beginner at least.
Basically I have a project consisting of two .cpp (zpaq.cpp and libzpaq.cpp) files and one .h (libzpaq.h) that I would like to make available to the BSD world.
It is a fork of a compressor with deduplication, in my opinion the most advanced in the category.
GitHub - fcorbelli/zpaqfranz: Deduplicating archiver with encryption and paranoid-level tests. Swiss army knife for the serious backup and disaster recovery manager. Ransomware neutralizer. Win/Linux/Unix
Deduplicating archiver with encryption and paranoid-level tests. Swiss army knife for the serious backup and disaster recovery manager. Ransomware neutralizer. Win/Linux/Unix - fcorbelli/zpaqfranz
github.com
So I would like to do the relative port first (in archivers) and then also the binary version, for pkg add.
The "make" is just like that
g++ -O3 -march=native -Dunix zpaq.cpp libzpaq.cpp -pthread -o zpaqfranz -static-libstdc++ -static-libgcc
or
clang++ -march=native -Dunix zpaq.cpp libzpaq.cpp -pthread -o zpaqfranz -static
Creating a single executable (zpaqfranz) to be putted into /usr/local/bin
Thanks for any reply