Why is the port FSV (File system Visualizer) broken on FreeBSD?

Ok great news gentlemen I was able to compile File System Visualizer and install it on FreeBSD 10.3-RELEASE AMD64 using the OpenBSD sources that are used by the OpenBSD 6.0 package at http://fedorchenko.net/fsv2.php. I ran it successfully on the FreeBSD X Window System and was able to browse my home directory using it. It makes sense that this version worked as they are both BSD operating systems. The trick was making sure each package that it required was installed when running the ./configure script. I had no luck using the GitHub sources as those were designed for Linux. It's been a long evening and I will look into the rest of the chapter 3 quick porting process on Sunday.

Code:
Dec 30 20:57:52 gordo pkg: gtkmm24-2.24.4_2 installed
Dec 30 21:03:45 gordo pkg: pangox-compat-0.0.2_1 installed
Dec 30 21:03:45 gordo pkg: gtkglext-1.2.0_18 installed
Dec 30 21:06:31 gordo pkg: gtkglextmm-1.2.0_10 installed
Dec 30 21:12:51 gordo pkg-static: gtkglarea-2.0.1_7 installed
Dec 30 21:14:41 gordo pkg: ftgl-2.1.3.r5_5,1 installed
 
Last edited by a moderator:
Ok I am on chapter 3 quick porting in the handbook and I am a bit confused on section 3.2.2. pkg-plist. How do I figure out all the files the port installs? When I built FSV from source I ran the make install command which installed the files. I see some output on the files it installed but the output is all over the place mixed up with other commands. Is there a better way of figuring this out?
 
q
You can use make makeplist > pkg-plist to generate the initial pkg-plist. You still have to check it afterwards however and make sure to remove the first line. See [2] and the tip in [1].

[1] https://www.freebsd.org/doc/en_US.I...-handbook/porting-desc.html#porting-pkg-plist
[2] https://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/plist-autoplist.html

I tried that command you stated and it didn't know how to make "makeplist". Here is the output from within the fsv source directory.

Code:
root@gordo:/home/antonio/fsv2-1.1.0 # make makeplist > /tmp/pkg-plist
make: don't know how to make makeplist. Stop
root@gordo:/home/antonio/fsv2-1.1.0 #
 
Does anyone else have any advice on how to build the the pkg-plist in the quick porting process? I received one suggestion but it did not work.
 
Did you have a look at this section? https://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/plist-autoplist.html

Note, make makeplist needs to be run inside the "port" you created, not the original source.

No I did not. I was reading Chapter 3 quick port so I did not jump to chapter 7.

Ok I did not know that. I ran the make makeplist inside the port directory I created with the two files "Makefile" and "pkg-descr" residing there. However I am running into a problem where when I run that command it's looking for a source file called fsv2-1.1.0.tar.gz but the file is called fsv2-1.1.0.tar.bz2 how can this be corrected? See below. The URL for the source file is http://fedorchenko.net/src/fsv2-1.1.0.tar.bz2

Code:
root@gordo:/home/antonio/fsv # make makeplist > /tmp/pkg-plist
fetch: http://fedorchenko.net/src/fsv2-1.1.0.tar.gz: Not Found
fetch: http://distcache.FreeBSD.org/ports-distfiles/fsv2-1.1.0.tar.gz: Not Found
root@gordo:/home/antonio/fsv #

Code:
root@gordo:/usr/ports/distfiles # cat /tmp/pkg-plist
/!\ fsv2-1.1.0: Makefile warnings, please consider fixing /!\

Not validating first entry in CATEGORIES due to being outside of PORTSDIR. Please ensure this is proper when committing.
Please set LICENSE for this port

===>   fsv2-1.1.0 depends on file: /usr/local/sbin/pkg - found
=> fsv2-1.1.0.tar.gz doesn't seem to exist in /usr/ports/distfiles/.
=> Attempting to fetch http://fedorchenko.net/src/fsv2-1.1.0.tar.gz
=> Attempting to fetch http://distcache.FreeBSD.org/ports-distfiles/fsv2-1.1.0.tar.gz
=> Couldn't fetch it - please try to retrieve this
=> port manually into /usr/ports/distfiles/ and try again.
*** Error code 1

Stop.
make: stopped in /usr/home/antonio/fsv
root@gordo:/usr/ports/distfiles #
 

The DISTFILES value in the make file worked thanks. DISTFILES= fsv2-1.1.0.tar.bz2.

I receive no errors when I run the command now. But when I check the output of the text file I redirected the output to it complains about a checksum file not being present. Is this normal?

Code:
root@gordo:/home/antonio/fsv # cat /tmp/pkg-plist
/!\ fsv2-1.1.0: Makefile warnings, please consider fixing /!\

Not validating first entry in CATEGORIES due to being outside of PORTSDIR. Please ensure this is proper when committing.
Please set LICENSE for this port

===>   fsv2-1.1.0 depends on file: /usr/local/sbin/pkg - found
===> Fetching all distfiles required by fsv2-1.1.0 for building
===>  Extracting for fsv2-1.1.0
=> No checksum file (/usr/home/antonio/fsv/distinfo).
*** Error code 1

Stop.
make: stopped in /usr/home/antonio/fsv
root@gordo:/home/antonio/fsv #
 
make makesum will download the file and create the correct checksums.

Thanks that worked it created the checksum file and I no longer get that error. However I am now getting a new error when I run the makeplist > /tmp/pkg-plist command. It states that it cannot open the Makefile but when I check the permissions on that file it is 755 so it should be able to open it right? Also the output of the /tmp/pkg-plist displays a make error with error code 1 probably related to the first error. Any input into what is wrong?

Code:
root@gordo:/home/antonio/fsv # make makeplist > /tmp/pkg-plist
make[1]: cannot open Makefile.
root@gordo:/home/antonio/fsv # cat /tmp/pkg-plist
===>  Building for fsv2-1.1.0

make[1]: stopped in /usr/home/antonio/fsv/work/fsv2-1.1.0
*** Error code 1

Stop.
make: stopped in /usr/home/antonio/fsv
root@gordo:/home/antonio/fsv #
 
Can you post the Makefile you have now? Doesn't matter if it's incomplete. I'm sure we can help out to make it work.
 
Can you post the Makefile you have now? Doesn't matter if it's incomplete. I'm sure we can help out to make it work.

Sure here is the output of my makefile:

Code:
root@gordo:/home/antonio/fsv # cat Makefile
# $FreeBSD$

PORTNAME=    fsv2
PORTVERSION=    1.1.0
CATEGORIES=    x11
DISTFILES=    fsv2-1.1.0.tar.bz2
MASTER_SITES=    http://fedorchenko.net/src/

MAINTAINER=    antonio@triforce.info
COMMENT=    3D filesystem visualizer

.include <bsd.port.mk>
root@gordo:/home/antonio/fsv #
 
Ok and where do I define GNU_CONFIGURE=yes within the make file itself?
Doesn't matter much, as long as it's above the bsd.port.mk line. But typically you keep the same order as things are executed. If you're not sure about things have a look at other ports. I regularly just look at how other ports deal with stuff then try to mimic what I need from it. Most ports have a fairly simple and straight-forward Makefile. Once you know which bit does what it's actually quite readable.

Code:
HEADER 

DEFINITIONS

CONFIGURE (options)

MAKE (options)

INSTALL (options)
 

Yeah I did that and I still receive the same error.

Code:
root@gordo:/home/antonio/fsv # cat Makefile
# $FreeBSD$

PORTNAME=    fsv2
PORTVERSION=    1.1.0
CATEGORIES=    x11
DISTFILES=    fsv2-1.1.0.tar.bz2
GNU_CONFIGURE=  yes
MASTER_SITES=    http://fedorchenko.net/src/

MAINTAINER=    antonio@triforce.info
COMMENT=    3D filesystem visualizer

.include <bsd.port.mk>
root@gordo:/home/antonio/fsv # make makeplist > /tmp/pkg-plist
make[1]: cannot open Makefile.
root@gordo:/home/antonio/fsv # cat /tmp/pkg-plist
===>  Building for fsv2-1.1.0

make[1]: stopped in /usr/home/antonio/fsv/work/fsv2-1.1.0
*** Error code 1

Stop.
make: stopped in /usr/home/antonio/fsv
root@gordo:/home/antonio/fsv #
 
Doesn't matter much, as long as it's above the bsd.port.mk line. But typically you keep the same order as things are executed. If you're not sure about things have a look at other ports. I regularly just look at how other ports deal with stuff then try to mimic what I need from it. Most ports have a fairly simple and straight-forward Makefile. Once you know which bit does what it's actually quite readable.

Code:
HEADER

DEFINITIONS

CONFIGURE (options)

MAKE (options)

INSTALL (options)

Ok I was looking at the mtr-nox11 port which I have installed on my FreeBSD system and it seems to have fewer lines than my Makefile and it works.

Code:
root@gordo:/usr/ports/net/mtr-nox11 # cat Makefile
# Created by: Sunpoet Po-Chuan Hsieh <sunpoet@FreeBSD.org>
# $FreeBSD: head/net/mtr-nox11/Makefile 383956 2015-04-13 19:25:28Z sunpoet $

PKGNAMESUFFIX=    -nox11

MASTERDIR=    ${.CURDIR}/../mtr

OPTIONS_EXCLUDE=X11
OPTIONS_FILE_UNSET=    X11

.include "${MASTERDIR}/Makefile"
root@gordo:/usr/ports/net/mtr-nox11 #
 
Do not forget to make clean after any alteration of Makefile. Things might be cached. Also, it's not worth to run make makeplist before ports actually compiles, as plist option runs after STAGE. Just simple make is enough.
 
Ok I was looking at the mtr-nox11 port which I have installed on my FreeBSD system and it seems to have fewer lines than my Makefile and it works.
That is a slave port (as defined by the MASTERDIR line). In that case, look at the master port as well.
Or choose a port which is not a slave port to use as an example.
 
Do not forget to make clean after any alteration of Makefile. Things might be cached. Also, it's not worth to run make makeplist before ports actually compiles, as plist option runs after STAGE. Just simple make is enough.

Ok I did that. make clean. Then I ran the make command by itself and it proceeded fine for a while but then generated several dependency errors. When I read the chapter 3 quick porting section it didn't state anything about dependencies where I am in making the make plist I guess I'm suppose add all these values to the make file?

Code:
libtool: install: /usr/bin/install -c .libs/libfsvui.so.0 /usr/home/antonio/fsv/work/stage/usr/local/lib/libfsvui.so.0
libtool: install: (cd /usr/home/antonio/fsv/work/stage/usr/local/lib && { ln -s -f libfsvui.so.0 libfsvui.so || { rm -f libfsvui.so && ln -s libfsvui.so.0 libfsvui.so; }; })
libtool: install: (cd /usr/home/antonio/fsv/work/stage/usr/local/lib && { ln -s -f libfsvui.so.0 libfsvui.so || { rm -f libfsvui.so && ln -s libfsvui.so.0 libfsvui.so; }; })
libtool: install: /usr/bin/install -c .libs/libfsvui.lai /usr/home/antonio/fsv/work/stage/usr/local/lib/libfsvui.la
libtool: install: /usr/bin/install -c .libs/libfsvui.a /usr/home/antonio/fsv/work/stage/usr/local/lib/libfsvui.a
libtool: install: chmod 644 /usr/home/antonio/fsv/work/stage/usr/local/lib/libfsvui.a
libtool: install: ranlib /usr/home/antonio/fsv/work/stage/usr/local/lib/libfsvui.a
libtool: install: warning: remember to run `libtool --finish /usr/local/lib'
test -z "/usr/local/include/fsv2" || /bin/mkdir -p "/usr/home/antonio/fsv/work/stage/usr/local/include/fsv2"
 install  -m 0644 'ColorCellRenderer.h' '/usr/home/antonio/fsv/work/stage/usr/local/include/fsv2/ColorCellRenderer.h'
 install  -m 0644 'ColorCellEditable.h' '/usr/home/antonio/fsv/work/stage/usr/local/include/fsv2/ColorCellEditable.h'
Making install in src
test -z "/usr/local/bin" || /bin/mkdir -p "/usr/home/antonio/fsv/work/stage/usr/local/bin"
  /bin/sh ../libtool   --mode=install install  -s -m 555 'fsv2' '/usr/home/antonio/fsv/work/stage/usr/local/bin/fsv2'
libtool: install: install -m 555 -s .libs/fsv2 /usr/home/antonio/fsv/work/stage/usr/local/bin/fsv2
test -z "/usr/local/share/applications" || /bin/mkdir -p "/usr/home/antonio/fsv/work/stage/usr/local/share/applications"
 install  -m 0644 'fsv2.desktop' '/usr/home/antonio/fsv/work/stage/usr/local/share/applications/fsv2.desktop'
====> Compressing man pages (compress-man)
====> Running Q/A tests (stage-qa)
Warning: 'lib/libfsvui.so.0' is not stripped consider trying INSTALL_TARGET=install-strip or using ${STRIP_CMD}
Error: .la libraries found, port needs USES=libtool
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libgtkmm-2.4.so.1 from x11-toolkits/gtkmm24 but it is not declared as a dependency
Warning: you need USE_GNOME+=gtkmm24
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libatkmm-1.6.so.1 from accessibility/atkmm but it is not declared as a dependency
Warning: you need USE_GNOME+=atkmm
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libgdkmm-2.4.so.1 from x11-toolkits/gtkmm24 but it is not declared as a dependency
Warning: you need USE_GNOME+=gtkmm24
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libgiomm-2.4.so.1 from devel/glibmm but it is not declared as a dependency
Warning: you need USE_GNOME+=glibmm
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libpangomm-1.4.so.1 from x11-toolkits/pangomm but it is not declared as a dependency
Warning: you need USE_GNOME+=pangomm
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libglibmm-2.4.so.1 from devel/glibmm but it is not declared as a dependency
Warning: you need USE_GNOME+=glibmm
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libcairomm-1.0.so.1 from graphics/cairomm but it is not declared as a dependency
Warning: you need USE_GNOME+=cairomm
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libsigc-2.0.so.0 from devel/libsigc++20 but it is not declared as a dependency
Warning: you need USE_GNOME+=libsigc++20
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libgtkgl-2.0.so.1 from x11-toolkits/gtkglarea2 but it is not declared as a dependency
Warning: you need LIB_DEPENDS+=libgtkgl-2.0.so:x11-toolkits/gtkglarea2
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libGLU.so.1 from graphics/libGLU but it is not declared as a dependency
Warning: you need USE_GL+=glu
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/.mesa/libGL.so from graphics/libGL but it is not declared as a dependency
Warning: you need USE_GL+=gl
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libgtk-x11-2.0.so.0 from x11-toolkits/gtk20 but it is not declared as a dependency
Warning: you need USE_GNOME+=gtk20
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libgdk-x11-2.0.so.0 from x11-toolkits/gtk20 but it is not declared as a dependency
Warning: you need USE_GNOME+=gtk20
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libpangocairo-1.0.so.0 from x11-toolkits/pango but it is not declared as a dependency
Warning: you need USE_GNOME+=pango
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libatk-1.0.so.0 from accessibility/atk but it is not declared as a dependency
Warning: you need USE_GNOME+=atk
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libcairo.so.2 from graphics/cairo but it is not declared as a dependency
Warning: you need USE_GNOME+=cairo
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libgdk_pixbuf-2.0.so.0 from graphics/gdk-pixbuf2 but it is not declared as a dependency
Warning: you need USE_GNOME+=gdkpixbuf2
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libgio-2.0.so.0 from devel/glib20 but it is not declared as a dependency
Warning: you need USE_GNOME+=glib20
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libpangoft2-1.0.so.0 from x11-toolkits/pango but it is not declared as a dependency
Warning: you need USE_GNOME+=pango
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libpango-1.0.so.0 from x11-toolkits/pango but it is not declared as a dependency
Warning: you need USE_GNOME+=pango
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libgobject-2.0.so.0 from devel/glib20 but it is not declared as a dependency
Warning: you need USE_GNOME+=glib20
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libglib-2.0.so.0 from devel/glib20 but it is not declared as a dependency
Warning: you need USE_GNOME+=glib20
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libintl.so.8 from devel/gettext-runtime but it is not declared as a dependency
Warning: you need USES+=gettext-runtime
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libfontconfig.so.1 from x11-fonts/fontconfig but it is not declared as a dependency
Warning: you need LIB_DEPENDS+=libfontconfig.so:x11-fonts/fontconfig
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libfreetype.so.6 from print/freetype2 but it is not declared as a dependency
Warning: you need LIB_DEPENDS+=libfreetype.so:print/freetype2
Error: /usr/local/bin/fsv2 is linked to /usr/local/lib/libftgl.so.2 from graphics/ftgl but it is not declared as a dependency
Warning: you need LIB_DEPENDS+=libftgl.so:graphics/ftgl
*** Error code 1

Stop.
make: stopped in /usr/home/antonio/fsv
root@gordo:/home/antonio/fsv #
 
Back
Top