Skip to content

fix sanity check error for OpenCV v4.5.1 by adding (and using) freetype and HarfBuzz dependencies#12517

Merged
boegel merged 1 commit intoeasybuilders:developfrom
guimou:fix-12491_OpenCV_4.5.1-foss-2020b-contribsanitycheckerror
Sep 1, 2021
Merged

fix sanity check error for OpenCV v4.5.1 by adding (and using) freetype and HarfBuzz dependencies#12517
boegel merged 1 commit intoeasybuilders:developfrom
guimou:fix-12491_OpenCV_4.5.1-foss-2020b-contribsanitycheckerror

Conversation

@guimou
Copy link
Copy Markdown
Contributor

@guimou guimou commented Apr 2, 2021

fixes #12491
Freetype and Harfbuzz are required to build freetype: https://github.com/opencv/opencv_contrib/tree/master/modules/freetype
=> Added those modules as dependencies

OpenCV contrib bug in ocv_check_modules prevents detection of Freetype and HarfBuzz, required to build freetype module, ref:

=> Applied configopts to "force detection" of the module as per described workaround in issue 2239.

Module requires Python 3:
=> Added configopt to disable Python2 compilation (removes error messages)

@boegel boegel added the bug fix label Apr 2, 2021
@boegel boegel added this to the 4.x milestone Apr 2, 2021
@boegel boegel changed the title Fixes #12491 - Sanity check error fix sanity check error for OpenCV v4.5.1 Apr 4, 2021
Comment thread easybuild/easyconfigs/o/OpenCV/OpenCV-4.5.1-foss-2020b-contrib.eb Outdated
@boegel boegel modified the milestones: 4.x, next release (4.3.4?) Apr 4, 2021
@easybuilders easybuilders deleted a comment from boegelbot Apr 6, 2021
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's this XXXXX configure option about?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's totally weird code in OpenCV to prevent configure from wiping _LINK_LIBRARIES: https://github.com/opencv/opencv/blob/6e8daaec0f46aaba9ea22e2afce47307b1dbff9f/cmake/OpenCVUtils.cmake#L861
It seems they put it there as a fix to prevent exactly what's happening, ocv_check_modules not being able to recognize freetype and harfbuzz...

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's worth adding a comment in the easyconfig file above this line to clarify that, because it looks really weird...

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment added (finally!)

@boegel
Copy link
Copy Markdown
Member

boegel commented Apr 6, 2021

@guimou It would be better to fix this in the OpenCV easyblock, or you up for looking into that?

@guimou
Copy link
Copy Markdown
Contributor Author

guimou commented Apr 6, 2021

@guimou It would be better to fix this in the OpenCV easyblock, or you up for looking into that?

I could have a look. But unless I'm mistaken, this easyblock does not include the contrib libraries? Which is why I guess @Micket created this package in the first place. I don't know, I just tried to correct this package so that I could install latest OpenCV version.

@boegel boegel modified the milestones: 4.4.0, release after 4.4.0 May 27, 2021
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's worth adding a comment in the easyconfig file above this line to clarify that, because it looks really weird...

@guimou guimou force-pushed the fix-12491_OpenCV_4.5.1-foss-2020b-contribsanitycheckerror branch from a339e49 to 9c92440 Compare August 30, 2021 12:28
@boegel
Copy link
Copy Markdown
Member

boegel commented Aug 31, 2021

@boegelbot please test @ generoso
CORE_CNT=16

@boegelbot
Copy link
Copy Markdown
Collaborator

@boegel: Request for testing this PR well received on generoso

PR test command 'EB_PR=12517 EB_ARGS= /apps/slurm/default/bin/sbatch --job-name test_PR_12517 --ntasks="16" ~/boegelbot/eb_from_pr_upload_generoso.sh' executed!

  • exit code: 0
  • output:
Submitted batch job 18250

Test results coming soon (I hope)...

Details

- notification for comment with ID 909609112 processed

Message to humans: this is just bookkeeping information for me,
it is of no use to you (unless you think I have a bug, which I don't).

@boegelbot
Copy link
Copy Markdown
Collaborator

Test report by @boegelbot
SUCCESS
Build succeeded for 2 out of 2 (2 easyconfigs in total)
generoso-x-1 - Linux centos linux 8.2.2004, x86_64, Intel(R) Xeon(R) CPU E5-2667 v3 @ 3.20GHz (haswell), Python 3.6.8
See https://gist.github.com/62c6e17fb5e053903b261ac1d48ae8ad for a full test report.

@boegel
Copy link
Copy Markdown
Member

boegel commented Aug 31, 2021

Test report by @boegel
SUCCESS
Build succeeded for 2 out of 2 (2 easyconfigs in total)
node3134.skitty.os - Linux centos linux 7.9.2009, x86_64, Intel(R) Xeon(R) Gold 6140 CPU @ 2.30GHz, Python 3.6.8
See https://gist.github.com/eff7ca71136493962d15e1836cd87aea for a full test report.

@boegel
Copy link
Copy Markdown
Member

boegel commented Sep 1, 2021

Going in, thanks @guimou!

@boegel boegel merged commit 51aecb0 into easybuilders:develop Sep 1, 2021
@boegel boegel changed the title fix sanity check error for OpenCV v4.5.1 fix sanity check error for OpenCV v4.5.1 by adding (and using) freetype and HarfBuzz dependencies Sep 1, 2021
@guimou guimou deleted the fix-12491_OpenCV_4.5.1-foss-2020b-contribsanitycheckerror branch September 12, 2021 13:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

OpenCV_4.5.1-foss-2020b-contrib sanity check error on libopencv_freetype.so

3 participants