Bug 218726

Summary: editors/calligra compilation error when DB options are disabled
Product: Ports & Packages Reporter: Grzegorz Junka <list1>
Component: Individual Port(s)Assignee: freebsd-kde (group) <kde>
Status: Closed FIXED    
Severity: Affects Some People CC: list1, tcberner
Priority: --- Flags: tcberner: maintainer-feedback+
Version: Latest   
Hardware: amd64   
OS: Any   
Attachments:
Description Flags
Poudriere failed build logs
none
fix linking against jpeg none

Description Grzegorz Junka 2017-04-18 11:14:51 UTC
Created attachment 181862 [details]
Poudriere failed build logs

Calligra doesn't compile when both databases are unchecked:

OPTIONS_FILE_UNSET+=MYSQL
OPTIONS_FILE_UNSET+=PGSQL

See attached log from poudriere.
Comment 1 Tobias C. Berner freebsd_committer freebsd_triage 2017-04-19 07:50:27 UTC
Ok, it seems that this is a red herring for an other issue, of -L/usr/local/lib -I/usr/local/include not being passed:
   /usr/bin/ld: cannot find -ljpeg

pgsql.mk seems to do this unconditionally, which is, why it works if PGSQL is enabled.

I'll fix this.
Comment 2 Tobias C. Berner freebsd_committer freebsd_triage 2017-04-19 08:19:30 UTC
Created attachment 181884 [details]
fix linking against jpeg

Could you please retry with attached diff?
Comment 3 commit-hook freebsd_committer freebsd_triage 2017-04-30 20:21:00 UTC
A commit references this bug:

Author: tcberner
Date: Sun Apr 30 20:20:32 UTC 2017
New revision: 439841
URL: https://svnweb.freebsd.org/changeset/ports/439841

Log:
  Fix linking against jpeg.

  As ${LOCALBASE}/lib is was not unconditionally part of the linker flags (only if
  POSTGRES option was selected), linking of calligra could fail with
  	 /usr/bin/ld: cannot find -ljpeg

  Fix it, by using ${JPEG_LIBRARY} as provided by cmake.

  PR:		218726
  Approved by:	rakuco (mentor)

Changes:
  head/editors/calligra/files/
  head/editors/calligra/files/patch-filters_karbon_pdf_CMakeLists.txt