Build package with customized port file using vcpkg - cmake

I installed OpenCV package using vcpkg, and since the OpenCV comes with vcpkg's own build configuration does not support libgtk, I got error when trying to run OpenCV with in WSL2 on windows 10.
The solution I found OpenCV GTK+2.x error suggests to add -DWITH_GTK=ON to the cmake configuration. And I added that option to the portfile in $vcpkgRoot/port/opencv4/porfile.make. And I try to rebuild/update the OpenCV, but seems it does not work.
I searched the documentation and could not find a clear description on how to use updated/customized portfile to rebuild the package. The only way that seems to work is to uninstall and install it again with the modified portfile.

If you used vcpkg install opencv and then used vcpkg remove opencv opencv4 will not be removed since the port opencv is just a redirection to opencv4. So if you want to remove opencv4 you need to use vcpkg remove opencv4 --recurse or vcpkg remove opencv opencv4. The same is true for e.g. openssl which needs to specific the platform e.g openssl-windows for correct removal.
And you cannot use the upgrade command since this requires a change of the version in the CONTROL file.

Related

how to start SCIP in Windows 7 when I want to use GCG

I want to use GCG's branch-and-price frame to solve a MIP which is similar to Binpacking problem. So I download the SCIPOptSuite-6.0.0-win64-VS15.exe and install it in Windows 7 and then install the Visual C++ Redistributable Packages which is required. Also I install the Cmake in Windows 7. But I do know how to do next after failed trying the instructions in the website https://scip.zib.de/doc-6.0.0/html/CMAKE.php (Installation information using CMake (recommended for new users)). I do not know where to start to compile. I even do not know whether the installation succeeds or not.
If you want to compile the code, you need to download the source package not the precompiled ones, as they don't include the source files.
As far as I know, GCG is not available in the precompiled packages, unfortunately.

How to install g++ in Cygwin?

I'm trying to compile a piece of MATLAB code containing a makefile. For the reason that I'm using Windows, I need to use Cygwin.
I have downloaded and installed Cygwin. When I tried to compile the code using make, there was an error that g++ is not found.
I searched for Cygwin package manager on the net and I installed apt-cyg but when I search for g++ using apt-cyg search g++, there is no result there!
I have updated package list (apt-cyg update) but finally I could not find c++ compiler for Cygwin!
How can I do it by apt-cyg package manager or any other way?
Try installing the package cygport. It will take care of many of the dependencies you need, including g++.
Finally I could find the answer in this link.
If one uses the MinGW installation file again, one can add some other packages.
I installed all Devel packages for MinGW and followed this tutorial which helped me to solve the problem.
If using apt-cyg and looking for g++ I would suggest to look up for the name gcc-g++ instead of just g++.
In this case the command would look like:
apt-cyg search gcc-g++ - for searching the package
or
apt-cyg install gcc-g++ - for installing the package
Hint:
Names of packages can be checked on the "Select Packages" page of the Cygwin installation program. There is no need to install, sometimes it is easier just to check the name of a package and cancel the installation.

Do I need to install wxWidget library separately when I download the wxFormbuilder?

I have recently started GUI development using wxwidget using C++ and MinGW.
Do I need to install wxWidget library separately when I download the wxFormbuilder?
Yes, you need wxwidgets installed to work with formbuilder. I suggest you to install codeblocks with mingw which you can find http://www.codeblocks.org/downloads/26 and follow this link https://wiki.wxwidgets.org/CodeBlocks_Setup_Guide to compling wxwidgets. When you are installing formbuilder for the first I guess it will ask for the location of wxwidgets installed directory so you need to have this or else you can setup this later.
Let me know if you have queries

wxWindows 2.9 binary for windows

After an upgrade to the new Haskell Platform, my existing wxHaskell programs are broken.
They all seem to now require wxWidgets 2.9, for which I can't find any binary versions.
wxPack has 2.8, and beyond that one has to get a compiler and build it locally from what I see.
There are tutorials on this from various sources, each a few pages long, with various advice on setup, changing configurations, etc. Install wxConfig, install minGW compilers, setup configurations, rebuild, etc.
Is there any source of a simple binary install? I'd hope for some simple apt-get or cabal like tool, Haskell library tools (on Windows?) seem less integrated than others that I'm familiar with.
(Update) I did install and compile wxWidgets locally, and still cannot get the wxHaskell components to install. I'm sure that all of this just requires some fairly simple details, but again after some time already, hope not to have to spend a lot more time on this, and wish it was more automated!
Configuring wxc-0.90.0.3...
Configuring wxc to build against wxWidgets 2.9
setup.exe: Missing dependencies on foreign libraries:
* Missing C libraries: wxmsw29ud_all, wxtiffd, wxjpegd, wxpngd, wxzlibd,
wxregexud, wxexpatd, wxregexud
This problem can usually be solved by installing the system packages that
provide these libraries (you may need the "-dev" versions). If the libraries
are already installed but in a non-standard location then you can use the
flags --extra-include-dirs= and --extra-lib-dirs= to specify where they are.
cabal: Error: some packages failed to install:
wx-0.90.0.1 depends on wxc-0.90.0.3 which failed to install.
wxc-0.90.0.3 failed during the configure step. The exception was: ExitFailure 1
wxcore-0.90.0.1 depends on wxc-0.90.0.3 which failed to install.
Yes, you can. CodeLite (C++ IDE I use) was recently upgraded to use wx29.
Since there are no binaries yet on repo, Dave set up some. Find all instruction in CodeLite's wiki below
wxWidgets 2.9 Packages and Repositories
If you are using windows Just go to download page for Codelite and download codelite with wxWidgets. Install it, copy the installed wxWidgets directory wherever it is needed!
Also it seems like there are official binaries. I have never tested download anything there so try yourself. The link is this one
Feel free to ask any question

How to develop and package with ActivePython?

I have been developing (a somewhat complicated) app on core python (2.6) and have also managed to use pyinstaller to create an executable for deployment in measurements, or distribution to my colleagues. I work on the Ubuntu OS.
What has troubled me is in upgrading the versions of numpy or scipy. Some features I need are in 0.9 and I'm still on 0.7. The process of upgrading them, or matplotlib, for that matter are not elegant. The way I've upgraded on my local machine was to delete the folders of these libraries, and then manually install the newer versions.
However, this does not work for machines where I do not have root access. While trying to find a workaround, I found ActivePython. I gave it a quick try and it seems to use PyPM to download the newest scipy and numpy to its custom install location. Excellent! I don't need root access and can use the latest version of the libraries.
QUESTION:
If there are libraries not available on the PyPM index with ActivePython, how can I directly use the source code of those libraries (example wxpython) to include into this installation?
How can I use pyinstaller to build an executable using only the libraries in the ActivePython installation?