I want to use FADE on my computer. So, I have to use the libaws++, which is a C++ library that allows to communicate with Amazon Web Services.
OK, Here is my problem:
The website of libaws++ is unavailable. I used Google to search "libaws++" and only found libaws. I didn't know whether libaws is libaws++. They both used to communicate with Amazon Web Services. So I download libaws from sourceforge.
Here is the process I install libaws:
tar libaws-0.9.2.tar.gz
cd libaws-0.9.2
cp ~/libaws_patch_for_fade.patch libaws_patch_for_fade.patch (cp the patch to libaws-0.9.2)
patch -p2 -i libaws_patch_for_fade.patch
mkdir libawsbuild
cd libawsbuild
cmake ..
make
And error occors:
[ 28%] Building CXX object src/CMakeFiles/aws.dir/api/connectionpool.cpp.o
In file included from /home/lx/Nutstore/cloud/libaws-0.9.2/include/libaws/aws.h: 26:0,
from /home/lx/Nutstore/cloud/libaws-0.9.2/include/libaws/connec tionpool.h:22,
from /home/lx/Nutstore/cloud/libaws-0.9.2/src/api/connectionpoo l.cpp:16:
/home/lx/Nutstore/cloud/libaws-0.9.2/include/libaws/sqsresponse.h:124:9: error: a€?uint64_ta€? does not name a type
In file included from /home/lx/Nutstore/cloud/libaws-0.9.2/include/libaws/aws.h: 29:0,
from /home/lx/Nutstore/cloud/libaws-0.9.2/include/libaws/connec tionpool.h:22,
from /home/lx/Nutstore/cloud/libaws-0.9.2/src/api/connectionpoo
/home/lx/Nutstore/cloud/libaws-0.9.2/include/libaws/sqsresponse.h:124:9: error: a€?uint64_ta€? does not name a type
In file included from /home/lx/Nutstore/cloud/libaws-0.9.2/include/libaws/aws.h: 29:0,
from /home/lx/Nutstore/cloud/libaws-0.9.2/include/libaws/connec tionpool.h:22,
from /home/lx/Nutstore/cloud/libaws-0.9.2/src/api/connectionpoo l.cpp:16:
/home/lx/Nutstore/cloud/libaws-0.9.2/include/libaws/sdbresponse.h:105:20: warning: type qualifiers ignored on function return type [-Wignored-qualifiers]
.....
make[2]: *** [src/CMakeFiles/aws.dir/api/connectionpool.cpp.o] Error 1
make[1]: *** [src/CMakeFiles/aws.dir/all] Error 2
make: *** [all] Error 2
I searched on Google and stackoverflow and didn't get any useful information.
Add #include <stdint.h> to the top of those header files.
uint64_t is a standard type and should work just fine.
(Unless of course you are on some weird platform that doesn't support 64-bit integers...)
Just got this compiled with the gnu compiler 4.9.x. With newer versions of the compiler, there are more steps needed to compile libaws.
Here's what I had to do:
1) Add the following line to the header files in libaws-0.9.2/include/libaws/*.h, after all of the other include statements:
#include <stdint.h>
2) Add the following line to libaws-0.9.2/include/libaws/aws.h, after all of the other include statements:
#include <getopt.h>
3) If you're using a recent version of the Gnu C++ compiler, you'll need to modify the CMAKE files to add some flags to the compiler, so that the older C++ syntax used in libaws doesn't throw compiler errors.
Add this line to CMakeCompiler.txt, after all of the other CMAKE_CXX_FLAGS commands, around line 82 (which should be a blank line):
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fpermissive -Wignored-qualifiers")
FYI: If you're using the Gnu C compiler, you may need a similar line for the C sections, at the end of the other CMAKE commands. Something like this at the end of the file might work, but I haven't tried it:
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fpermissive -Wignored-qualifiers")
Once those are done, here are the steps to compile:
cd libaws-0.9.2
mkdir libawsbuild
cd libawsbuild
cmake ..
make
When this is successful, you also may need to copy config.h from libawsbuild/include to libaws-0.9.2/include/libaws in order for the compiler to find config.h in the place it expects, when you compile whatever code you're writing to actually use libaws. (Although that may just have been the way my personal makefile was configured. Don't quote me on that.)
Related
I am on Ubuntu.
I am trying to build a simple project that I know worked! (I already made it work) I don't think I changed something to it but it has been three days and I cannot find a way to make it build again.
I use a library named pico-DMX, whenever I don't add it to my project with "include" in cmake, than the make starts building.
Otherwise, if I include the library in the cmake code, cmake .. command process and generate normally but the build ctrying to build a simple project that I know workedrashes instantaneously. I cannot seem to understand where it comes from.
This is the error message:
PICO_SDK_PATH is /home/andrew/pico/pico-sdk
PICO platform is rp2040.
Build type is Release
PICO target board is pico.
Using board configuration from /home/andrew/pico/pico-sdk/src/boards/include/boards/pico.h
TinyUSB available at /home/andrew/pico/pico-sdk/lib/tinyusb/src/portable/raspberrypi/rp2040; enabling build support for USB.
cyw43-driver available at /home/andrew/pico/pico-sdk/lib/cyw43-driver
lwIP available at /home/andrew/pico/pico-sdk/lib/lwip
-- Configuring done
-- Generating done
-- Build files have been written to: /home/andrew/pico/serial_pico (copy)/build
Scanning dependencies of target bs2_default
[ 1%] Building ASM object pico-sdk/src/rp2_common/boot_stage2/CMakeFiles/bs2_default.dir/compile_time_choice.S.obj
[ 2%] Linking ASM executable bs2_default.elf
/bin/sh: 1: Syntax error: "(" unexpected
make[2]: *** [pico-sdk/src/rp2_common/boot_stage2/CMakeFiles/bs2_default.dir/build.make:98: pico-sdk/src/rp2_common/boot_stage2/bs2_default.elf] Error 2
make[2]: *** Deleting file 'pico-sdk/src/rp2_common/boot_stage2/bs2_default.elf'
make[1]: *** [CMakeFiles/Makefile2:1493: pico-sdk/src/rp2_common/boot_stage2/CMakeFiles/bs2_default.dir/all] Error 2
make: *** [Makefile:91: all] Error 2
This is my main cmake files:
cmake_minimum_required(VERSION 3.13)
include($ENV{PICO_SDK_PATH}/pico_sdk_init.cmake)
project(usb_control C CXX ASM)
set(CMAKE_CXX_STANDARD 17)
pico_sdk_init()
include($ENV{HOME}/pico/libraries/lib/Pico-DMX/interfaceLibForPicoSDK.cmake)
add_executable(usb_control
main.cpp
)
target_link_libraries(usb_control picodmx pico_stdlib hardware_pio hardware_dma)
pico_enable_stdio_usb(usb_control 1)
pico_enable_stdio_uart(usb_control 0)
pico_add_extra_outputs(usb_control)
The previous cmake file include $ENV{HOME}/pico/libraries/lib/Pico-DMX/interfaceLibForPicoSDK.cmake which contains :
## Include this file if you want to use the Pico-DMX library
## in YOUR (Pico-C-SDK-based) project.
cmake_minimum_required(VERSION 3.12)
# Define the Pico-DMX library
add_library(picodmx INTERFACE)
target_sources(picodmx INTERFACE
${CMAKE_CURRENT_LIST_DIR}/src/DmxInput.cpp
${CMAKE_CURRENT_LIST_DIR}/src/DmxOutput.cpp
)
pico_generate_pio_header(picodmx
${CMAKE_CURRENT_LIST_DIR}/extras/DmxInput.pio
)
pico_generate_pio_header(picodmx
${CMAKE_CURRENT_LIST_DIR}/extras/DmxOutput.pio
)
target_include_directories(picodmx INTERFACE
${CMAKE_CURRENT_LIST_DIR}/src
)
Again, I know there are no mistakes in the C++ code, it worked! It started to bug and wouldn't work again when I played with the Cmake to include directly the library dependencies of pico-dmx in its cmake file.
If you have any questions feel free to ask, I'll answer quickly. In advance thank you for your help
As mentioned in the comments, the cause is the name of your directory. In order to accurately explain why it happens, I reproduced your situation myself. I created a dummy project under "/tmp/test checkout (copy)" and built using CMake:
cd "/tmp/test checkout (copy)/build/pico-sdk/src/rp2_common/boot_stage2" && \
arm-none-eabi-objdump -h /tmp/test\ checkout\ (copy)/build/pico-sdk/src/rp2_common/boot_stage2/bs2_default.elf >bs2_default.dis
Note that the spaces in the full filename are correctly escaped with a backslash, but the parentheses are not. This confuses the shell.
I raised this issue on the Pico SDK. Until it is fixed, (EDIT: it was fixed in Dec 2022) people should steer clear of using special characters in their directory structures. This is a good recommendation in general as it avoids situations like these.
I am trying to use opencv in a project, and am running into problems 'installing' it. I have extracted the opencv files and have created a small test program:
#include "opencv2/highgui/highgui.hpp"
#include <iostream>
int main(int argc, char **argv){
cv::Mat im=cv::imread((argc==2)? argv[1]: "testing.jpg",1);
if (im.empty()){
std::cout << "Cannot open image." << std::endl;
} else {
cv::imshow("image",im);
cv::waitKey(0);
}
return 0;
}
To compile the program I have used the command below:
g++ -I"../../PortableGit/opt/opencv/build/include/" -L"../../PortableGit/opt/opencv/build/x64/vc15/lib" main.cpp -lopencv_core -lopencv_highgui -o main
I get the errors below:
In file included from ../../PortableGit/opt/opencv/build/include/opencv2/core.hpp:3293:0,
from ../../PortableGit/opt/opencv/build/include/opencv2/highgui.hpp:46,
from ../../PortableGit/opt/opencv/build/include/opencv2/highgui/highgui.hpp:48,
from main.cpp:1:
../../PortableGit/opt/opencv/build/include/opencv2/core/utility.hpp:714:14: error: 'recursive_mutex' in namespace 'std' does not name
a type
typedef std::recursive_mutex Mutex;
^~~~~~~~~~~~~~~
../../PortableGit/opt/opencv/build/include/opencv2/core/utility.hpp:715:25: error: 'Mutex' is not a member of 'cv'
typedef std::lock_guard<cv::Mutex> AutoLock;
^~
../../PortableGit/opt/opencv/build/include/opencv2/core/utility.hpp:715:25: error: 'Mutex' is not a member of 'cv'
../../PortableGit/opt/opencv/build/include/opencv2/core/utility.hpp:715:34: error: template argument 1 is invalid
typedef std::lock_guard<cv::Mutex> AutoLock;
I believe that it has something to do with mingw binaries no longer being included with opencv. I am missing the opencv/build/x86/mingw directory.
My questions are:
How do I 'install' opencv and use it without also installing some sort of IDE and/or CMake? (I prefer to use vim and the command line.)
Once installed, what command do I use to compile and link a program with opencv?
Any help is appreciated.
Edit:
This appears to be a problem with GCC's implementation of threads on windows. Using mingw-w64 instead of mingw fixed the std::recursive_mutex issue, but now the linker cannot find the proper files.
/i686-w64-mingw32/bin/ld.exe: cannot find -lopencv_core
/i686-w64-mingw32/bin/ld.exe: cannot find -lopencv_highgui
After quite a bit of trying things out, this is what I got to work. Oddly, following the LINUX guide to install opencv worked better than the WINDOWS guide, even though I have a windows computer.
Guide to Installing OpenCV on Windows Without VS
Heads-up: This is a multi-step process, 3 separate tools are required. Be prepared for this to take a while.
Part 1: Get everything ready
Download MinGW-w64.
On the downloads page, click on the "MinGW-w64-builds" option. Do not click on the "win-builds" option.
The reason MinGW-w64 has to be used is because it is a newer version of the MinGW compiler suit that has been improved for windows. This means that it supports the posix thread system, where as the standard MinGW compiler only supports the win32 thread system. OpenCV relies on the posix thread system, necessitating the MinGW-w64 compiler.
Extract the MinGW-w64 zip folder to a directory. In my case its PortableGit/opt/MinGW-w64
At this point, you can add the MingGW-w64/mingw32/bin folder to your path. (Assuming that this won't cause any conflicts.) If you do so, you will not have to constantly specify the g++ executable directory to run it. This is up to your discretion.
Download an opencv release.
Do not download the package for windows, click the button that says "sources"
Extract the opencv sources zip folder to a directory. In my case its PortableGit/opt/opencv-4.3.0
Also download the opencv_contrib source files directly from the repository.
Extract that folder and place it inside the top level opencv folder: PortableGit/opt/opencv-4.3.0/opencv_contrib in my case.
Download CMake.
I downloaded the zip folder, but you can download the installer if you wish.
Extract the CMake zip folder if you downloaded that, or run the installer. I put my CMake folder here: PortableGit/opt/cmake-3.17.1-win32-x86
At this point, you can add the cmake-3.17.1-win32-x86/bin folder to your path. (Assuming that this won't cause any conflicts.) If you do so, you will not have to constantly specify the cmake executable directory to run it. This is up to your discretion.
Part 2: Build OpenCV
Navigate to the opencv directory and create a build folder and cd into it.
mkdir build && cd build
Run the following export commands.
export CC=/PortableGit/MinGW-w64/mingw32/bin/gcc.exe
export CXX=/PortableGit/MinGW-w64/mingw32/bin/g++.exe
This is to make sure the next cmake command uses the proper compilers.
Run the following cmake command from within that folder:
PortableGit/opt/cmake-3.17.1-win32-x86/cmake.exe -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=Release -DOPENCV_VS_VERSIONINFO_SKIP=1 -DOPENCV_EXTRA_MODULES_PATH="/PortableGit/opt/opencv-4.3.0/opencv_contrib/modules/" ..
The -G flag specifies that we are creating build files for the MinGW compiler
The -DCMAKE_BUILD_TYPE=Release specifies that we are building the release version of opencv and not the debug version.
The DOPENCV_EXTRA_MODULES_PATH needs to be set to the modules folder inside the opencv_contrib folder. For me it was PortableGit/opt/opencv-4.3.0/opencv_contrib/modules
The DOPENCV_VS_VERSIONINFO_SKIP specifies to not include version info. If not set, the compiler will throw an error complaining about not having version files. (Shown below for reference.)
gcc: error: long: No such file or directory
mingw32-make[2]: *** [modules\core\CMakeFiles\opencv_core.dir\build.make:1341:
modules/core/CMakeFiles/opencv_core.dir/vs_version.rc.obj] Error 1
If successful, the cmake command will finish like this:
Now run this command, again from the build folder: /PortableGit/opt/MinGW-w64/mingw32/bin/mingw32-make.exe -j7
mingw32-make.exe is the windows equivalent of the Linux make command.
The -j7 option run the process with a maximum of 7 threads.
This will take a while! It took my laptop ~20 minutes to complete
If the make command ends in an error, make sure to reset your build directory before continuing any troubleshooting. This is done through this series of commands
rm -rf build
mkdir build
cd build
Part 3: Using OpenCV
To use the opencv library that you just compiled in a project of your own, compile the project with these flags from your projects main directory.
Remember that your compiler now has to be set to the mingw-w64 compiler for opencv support.
I added indentation and newlines for readability, but when entering this in the terminal do not include the newlines or indents.
The number at the end of the linker options may change depending on the version of opencv you downloaded. I downloaded opencv-4.3.0, making my number 430, but yours may be different.
PortableGit/opt/MinGW-w64/bin/g++.exe
-I../../PortableGit/opt/opencv-4.3.0/include/
-I../../PortableGit/opt/opencv-4.3.0/build/
-I../../PortableGit/opt/opencv-4.3.0/modules/core/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/calib3d/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/dnn/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/features2d/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/flann/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/gapi/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/highgui/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/imgcodecs/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/imgproc/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/ml/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/objdetect/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/photo/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/stitching/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/ts/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/video/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/videoio/include/
-I../../PortableGit/opt/opencv-4.3.0/modules/world/include/
-L../../PortableGit/opt/opencv-4.3.0/build/lib/
*.hpp
*.cpp
-lopencv_calib3d430
-lopencv_core430
-lopencv_dnn430
-lopencv_features2d430
-lopencv_flann430
-lopencv_highgui430
-lopencv_imgcodecs430
-lopencv_imgproc430
-lopencv_ml430
-lopencv_objdetect430
-lopencv_photo430
-lopencv_stitching430
-lopencv_video430
-lopencv_videoio430
-o
main
Or you could download VS. Up to you. Hope this helps.
Correction for JackCamichael's answer
those 2 commands won't work in Windows
export CC=/PortableGit/MinGW-w64/mingw32/bin/gcc.exe
export CXX=/PortableGit/MinGW-w64/mingw32/bin/g++.exe
This should be
setx -m CC C:\msys64\mingw64\bin\gcc.exe
setx -m CXX C:\msys64\mingw64\bin\g++.exe
C:\msys64\mingw64\bin is mingw64 path on my machine
I've been trying to install the nana library for c++. I've used these guides:
https://github.com/qPCR4vir/nana-docs/wiki/Installation
https://github.com/qPCR4vir/nana-docs/wiki/Install-and-use-nana-with-mingw---step-by-step
I got stuck on the part that says "Create a static linkage library solution within a IDE/build system you use, and add all the files which are placed in NanaPath/source and in all its sub directories to the project. Then compile the solution and you will get a static linkage file NanaStatic in a path similar to NanaPath/build/bin/IDEName."
I downloaded MinGW, git, and cmake like it said. I opened up the bat file, ran the "git clone" with the link, ran
cmake -G "MinGW Makefiles"
It did it's thing and finished successfully. Then I tried running "make" and it got to 6% when this showed up:
In file included from C:/Users/.../nana/verbose_prepocessor.hpp:99:0,
from C:\Users\...\nana\source\deploy.cpp:242:C/Users/.../nana/include/filesystem/filesystem.hpp:71:39: fatal error: experimental/filesystem: No such file or directory
# include<experimental/filesystem>
^
compilation terminated.
make[2]: *** [CMakeFiles\nana.dir\build.make:163: CMakeFiles/nana.dir/source/deploy.cpp.obj] Error 1
make[1]: *** [CMakeFiles\Makefile2:67: CMakeFiles/nana.dir/all] Error 2
make: *** [Makefile:129: all] Error 2
I tried using a different source of the code (git and sourceforge) and that didn't make a difference. I tried using the GUI cmake, but I had other errors with that not recognizing MinGW. I looked around for answers online, but they mostly led back to the guides I was using. I checked my GCC and G++ version with gcc/g++ --version, and they're both 6.3.0.
I'll take any suggestions/advice, thanks!
I have not used Eclipse, so I cant help with that. But I will try to help with nana:
Originaly there was no std::filesystem and nana offered one JinHao invented. With the apparition of std::experimental::filsystem candidate, an experimental filesystem in the sdt:: c++ library of some versions of some compilers we adapted the nana filesystem to be a partial implementation of that. Then nana try to configure itself to use the provided std:: (or Boost) implementation or if it is not there then nana::filesystem. It seems like MinGW have problems with filesystem, I'm not sure about that but here you can read: https://github.com/Alexpux/MINGW-packages/issues/2292
Please try to undertstand what is going on in your case an let us know about. We will then try to fix the configuration of nana to work even in that situation.
You can always simply choise to (force) use the nana implementation. Just please compile both the nana library and your project with all the same options, including what filesytem you use. For example adding -DNANA_CMAKE_NANA_FILESYSTEM_FORCE=True to your cmake or define NANA_FILESYSTEM_FORCE in your built system (or IDE).
I am trying to compile tensorflow with a custom clang/llvm toolchain and using clang's native libc++ (instead of borrowing Gcc's stdlibc++).
It looks like bazel plain assumes that every clang will use Gcc's libraries because I get these errors:
$ bazel build --cxxopt=-std=c++11 --cxxopt=-stdlib=libc++ tensorflow:libtensorflow.so
INFO: Found 1 target...
INFO: From Compiling
external/protobuf/src/google/protobuf/compiler/js/embed.cc [for host]:
external/protobuf/src/google/protobuf/compiler/js/embed.cc:37:12:
warning: unused variable 'output_file' [-Wunused-const-variable]
const char output_file[] = "well_known_types_embed.cc";
^
1 warning generated.
ERROR: /home/hbucher/.cache/bazel/_bazel_hbucher/ad427c7fddd5b68de5e1cfaa7cd8c8cc/external/com_googlesource_code_re2/BUILD:11:1: undeclared inclusion(s) in rule '#com_googlesource_code_re2//:re2':
this rule is missing dependency declarations for the following files included by 'external/com_googlesource_code_re2/re2/bitstate.cc':
'/home/hbucher/install/include/c++/v1/stddef.h'
'/home/hbucher/install/include/c++/v1/__config'
I tried to hack into tools/cpp/CROSSTOOL inside bazel as some posts suggested to add the line
cxx_builtin_include_directory: "/home/hbucher/install/include/c++/v1"
but to no avail, it does not seem to make any difference.
Then I tried to follow a bazel tutorial to create a custom toolchain. The text does not help much because they are actually writing a cross tool while what I am trying to do is to tweak the existing host rules and somehow bazel seems to undo every attempt I try to tweak its parameters.
I have got to the point that is currently in my github repository https://github.com/HFTrader/BazelCustomToolchain
However it does not compile and I cannot even figure out how to start debugging this message.
$ bazel build --crosstool_top=#hbclang//:toolchain tensorflow:libtensorflow.so
.....................
ERROR: The crosstool_top you specified was resolved to
'#hbclang//:toolchain', which does not contain a CROSSTOOL file. You can
use a crosstool from the depot by specifying its label.
INFO: Elapsed time: 2.216s
I have appended these lines to my tensorflow/WORKSPACE
new_local_repository(
name="hbclang",
path="/home/hbucher/BazelCustomToolchain",
build_file = "/home/hbucher/BazelCustomToolchain/BUILD",
)
I have asked this question on bazel's google groups but they redirected me to stackoverflow. At this point I am about to give up.
Have someone attempted to do this or I'm breaking ground here?
Thank you.
Solved. Not in the intended way but it works for me.
export INSTALL_DIR="$HOME/install"
export CC=$INSTALL_DIR/bin/clang
export CXX=$INSTALL_DIR/bin/clang++
export CXXFLAGS="-stdlib=libc++ -L$INSTALL_DIR/lib"
export LDFLAGS="-L$INSTALL_DIR/lib -lm -lrt"
export LD_LIBRARY_PATH="/usr/lib:/lib/x86_64-linux-gnu/:$INSTALL_DIR/lib"
git clone https://github.com/tensorflow/tensorflow.git tensorflow-github
cd tensorflow-github
mkdir build-tmp && cd build-tmp
cmake ../tensorflow/contrib/cmake/
make -j4
Easy as 1-2-3 with cmake
[2020-05-24: Edit to make the answer up to date.]
TLDR: To build a project with Bazel with a specific Clang binary, and with libc++, this works for me (where INSTALL_DIR is where I've installed llvm):
CC="$INSTALL_DIR/bin/clang" \
BAZEL_CXXOPTS="-stdlib=libc++:-isystem$INSTALL_DIR/include" \
BAZEL_LINKOPTS="-stdlib=libc++" \
BAZEL_LINKLIBS="-L$INSTALL_DIR/lib:-Wl,-rpath,$INSTALL_DIR/lib:-lc++:-lm" \
bazel test //...
Background:
You can use --repo_env option, e.g. --repo_env=CC=clang, to put these defaults into your project- or system-wide .bazelrc.
This approach uses Bazel's C++ toolchain autoconfiguration which doesn't attempt to declare all the toolchain inputs in BUILD files. This is to simplify the configuration for the user. Therefore whenever you modify the C++ toolchain in a way that Bazel cannot know about (rebuild llvm etc.), you have to run bazel clean --expunge to flush the cache and rerun the autoconfiguration the next time.
The robust solution to specifying C++ toolchain in Bazel is to use the CcToolchainConfigInfo. See the documentation at https://docs.bazel.build/versions/master/tutorial/cc-toolchain-config.html and https://docs.bazel.build/versions/master/cc-toolchain-config-reference.html.
I am trying to install Subversion on my computer. I have a source code I am supposed to compile, just like a C library, which I find tricky because I am not used to it.
In the folder, there are, among other files:
configure.ac
Makefile.in
In the readme, it says I have to use the standard GNU procedure to compile:
$ ./configure
$ make
# make install
But when writing gcc ./configure.ac in the command line, it says
C:\Users\SC5\Downloads\subversion-1.8.9\subversion-1.8.9>gcc configure.ac
c:/strawberry/c/bin/../lib/gcc/x86_64-w64-mingw32/4.7.3/../../../../x86_64-w64-m
ingw32/bin/ld.exe:configure.ac: file format not recognized; treating as linker s
cript
c:/strawberry/c/bin/../lib/gcc/x86_64-w64-mingw32/4.7.3/../../../../x86_64-w64-m
ingw32/bin/ld.exe:configure.ac:1: syntax error
collect2.exe: error: ld returned 1 exit status
Any idea? A general path on how to install with .config files in general?
Thanks very much for any help.
If you are using windows, just download the .exe and hit enter on it.