Bug 203204 - [NEW PORT] databases/pgmodeler: PostgreSQL Database Modeler
Summary: [NEW PORT] databases/pgmodeler: PostgreSQL Database Modeler
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2015-09-19 10:11 UTC by Loïc Bartoletti
Modified: 2016-09-21 20:12 UTC (History)
1 user (show)

See Also:


Attachments
pgmodeler port (23.75 KB, patch)
2015-09-19 10:11 UTC, Loïc Bartoletti
no flags Details | Diff
Shar version of the port (20.80 KB, text/plain)
2016-02-27 07:15 UTC, Loïc Bartoletti
lbartoletti: maintainer-approval+
Details
port with modifications from Raphael Kubo da Costa (14.26 KB, text/plain)
2016-03-03 05:13 UTC, Loïc Bartoletti
lbartoletti: maintainer-approval+
Details
port with new modifications from Raphael Kubo da Costa (14.52 KB, patch)
2016-04-30 08:23 UTC, Loïc Bartoletti
lbartoletti: maintainer-approval+
Details | Diff
pgmodeler v0.8.2 (14.78 KB, text/plain)
2016-08-13 07:31 UTC, Loïc Bartoletti
lbartoletti: maintainer-approval+
Details
port with new modifications from Raphael Kubo da Costa (14.17 KB, patch)
2016-09-21 04:12 UTC, Loïc Bartoletti
lbartoletti: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Loïc Bartoletti freebsd_committer freebsd_triage 2015-09-19 10:11:17 UTC
Created attachment 161185 [details]
pgmodeler port

pgModeler - PostgreSQL Database Modeler - is an open source data modeling tool designed for PostgreSQL. No more DDL commands written by hand let pgModeler do the job for you! This software reunites the concepts of entity-relationship diagrams and the features that PostgreSQL implements as extensions of SQL standards.
http://pgmodeler.com.br




Logs:
http://download.tuxfamily.org/bartcoding/ports/pgmodeler/
Comment 1 Loïc Bartoletti freebsd_committer freebsd_triage 2016-02-27 07:15:05 UTC
Created attachment 167470 [details]
Shar version of the port

The precedent patch was a svn diff and not a shar file. Sorry.
Comment 2 Raphael Kubo da Costa freebsd_committer freebsd_triage 2016-02-28 13:10:58 UTC
I've taken a look at the new port and have some comments and suggestions:

* You should set USE_GITHUB to "yes" instead of just defining it. Just defining it also works, but it's not the common idiom used in the tree.

* You don't need to set GH_PROJECT if it has the same value as PORTNAME.

* You also don't need to set GH_TAGNAME: there's an actual 0.8.1 release on GitHub, so just setting PORTVERSION and DISTVERSIONPREFIX works just fine. You'll need to re-run make makesum though as the file name will change.

* Once you do that, setting WRKSRC is also not necessary.

* qt5-dbus and qt5-imageformats do not seem to be actual dependencies after taking a look at the code.

* Including bsd.port.{pre,post}.mk just because you are setting some targets is not necessary. Just including bsd.port.mk at the end works fine.

* Now speaking of those targets and your patches in files/:
  - Most of those patches become unnecessary if you use USES=qmake instead of USES=qmake:outsource. Unfortunately the upstream code seems to assume you are not doing an out-of-tree build and references things like $$PWD in the .pro files. Instead of doing a lot of patching, it is much easier to just not do an out-of-tree build until upstream fixes this.
  - I don't see why you are enabling the installation of the plugins. It requires additional patching and upstream seems to have made a conscious choice of only building tests and samples in a debug build. You should also maybe add a DEBUG option and handle those additional plugin files in pkg-plist with the %%DEBUG%% variable.
  - Personally, I don't like performing sed calls like the ones you do in the post-patch target. Having actual patch files makes it easier for other people to see what is being changed and why.
  - When patching main.pro and main-cli.pro, you could use $$QMAKE_LIBS_EXECINFO instead of -lexecinfo directly.
Comment 3 Loïc Bartoletti freebsd_committer freebsd_triage 2016-03-03 05:13:08 UTC
Created attachment 167670 [details]
port with modifications from Raphael Kubo da Costa
Comment 4 Loïc Bartoletti freebsd_committer freebsd_triage 2016-03-03 05:13:25 UTC
Hello,

Thank you for all you advice. I rebuilt the port.

Just for plugins, I need to let it because without it, the app show an error message.

Is it better for you?

Thanks.
Comment 5 Raphael Kubo da Costa freebsd_committer freebsd_triage 2016-03-05 12:28:01 UTC
Hi,

I tried building this new port in debug mode with WITH_DEBUG=yes, and it has issues:
- It's missing USE_QT5=testlib because the tests are built when debug mode is on.
- The patch-pgmodeler.pro ends up duplicating the SUBDIRS=plugins entry because it's also enabled by default in debug mode. I think it makes more sense to do the following check with just a SUBDIRS entry.
  CONFIG(debug, debug|release): SUBDIRS += tests plugins
- The tests subdirectory installs some binaries that should be removed in post-install: bin/tests/baseobjecttest, bin/tests/roletest, bin/tests/runtests and bin/tests/syntaxhighlightertest. ${RM} -f ${STAGEDIR}${PREFIX}/bin/tests/ should do the job. Alternatively, you could remove the installation parts in tests/tests.pri.
Comment 6 Loïc Bartoletti freebsd_committer freebsd_triage 2016-04-30 08:23:38 UTC
Created attachment 169821 [details]
port with new modifications from Raphael Kubo da Costa

Is this new port ok for you?

Regards.
Comment 7 Loïc Bartoletti freebsd_committer freebsd_triage 2016-08-13 07:31:44 UTC
Created attachment 173619 [details]
pgmodeler v0.8.2

New version of pgmodeler

Portlint OK
Poudriere 9, 10, 11 amd64 and i386
Comment 8 Raphael Kubo da Costa freebsd_committer freebsd_triage 2016-08-20 20:06:07 UTC
Hi there,

Sorry for the absence. I've finally taken a look at the latest patch (0.8.2) and only have some comments with things that should be improved before landing:
- You don't need both USES=qmake and USE_QT5=qmake_build; USES=qmake is enough.
- GH_ACCOUNT=pgmodeler is redundant; the ports framework uses ${PORTNAME} by default.
- You should just use "lib" instead of the occurrences of "%%QT_LIBDIR%%" in pkg-plist. The latter should be used only by the Qt ports themselves in general.

Thanks for the work; again, I apologize for taking so long to review the patch, at least we're really close now!
Comment 9 Loïc Bartoletti freebsd_committer freebsd_triage 2016-09-21 04:12:36 UTC
Created attachment 175026 [details]
port with new modifications from Raphael Kubo da Costa
Comment 10 commit-hook freebsd_committer freebsd_triage 2016-09-21 20:11:14 UTC
A commit references this bug:

Author: rakuco
Date: Wed Sep 21 20:11:10 UTC 2016
New revision: 422577
URL: https://svnweb.freebsd.org/changeset/ports/422577

Log:
  New port: databases/pgmodeler

  pgModeler - PostgreSQL Database Modeler - is an open source data modeling
  tool designed for PostgreSQL. No more DDL commands written by hand let
  pgModeler do the job for you! This software reunites the concepts of
  entity-relationship diagrams and the features that PostgreSQL implements as
  extensions of SQL standards.

  WWW: http://pgmodeler.com.br/

  PR:		203204
  Submitted by:	lbartoletti@tuxfamily.org

Changes:
  head/databases/Makefile
  head/databases/pgmodeler/
  head/databases/pgmodeler/Makefile
  head/databases/pgmodeler/distinfo
  head/databases/pgmodeler/files/
  head/databases/pgmodeler/files/patch-main-cli_main-cli.pro
  head/databases/pgmodeler/files/patch-main_main.pro
  head/databases/pgmodeler/files/patch-pgmodeler.pro
  head/databases/pgmodeler/pkg-descr
  head/databases/pgmodeler/pkg-plist
Comment 11 Raphael Kubo da Costa freebsd_committer freebsd_triage 2016-09-21 20:12:14 UTC
Finally committed, thanks for working on this!