redhat6: how to uninstall package when it's installed from source - uninstallation

I installed a package from its source files by using "make install", if I want to remove the package, how should I do? I looked into Makefile, but not many options.
Thanks in advance
Yang

Usually when you use make install, there is no good way to uninstall. This is why it's often advisable to use the --prefix option to the configure script to specify a special directory for each application that's installed in this way.
Another good option is to make the extra effort to pack up an RPM, then you can use rpm to install and uninstall. But it's too late for you to do this after you've already done the install.
So, I think you will be left to try to find the files that were installed and remove them individually. Hopefully the makefile installed to /usr/local instead of /usr.
You might try searching by time range, that way you might be able to find all the files that were installed at the same time.

Related

Install library built with Bazel

First time bazel user here. I've compiled a library [1], but I'm missing how to install it to prefix /usr/local.
Sure I can always copy it around. But what is the bazel way of doing it?
[1] https://github.com/google/jwt_verify_lib
Check out https://github.com/google/bazel_rules_install. The feature set seems to support install prefixes.
I'm not aware of a standard Bazel solution here.
If the build result is self-contained, copying looks acceptable.
If on Linux, consider https://github.com/bazelbuild/rules_pkg. It can produce rpm or deb package, which can be then installed by the respective package manager.

Where does Bower install my packages?

Ok, be forewarned, I am SUPER noob when it comes to bower. I have a very sketchy basic understanding of what it even is and barely know how to do anything on it. So bear with me here. Also, I'm working on Windows here.
I installed node.js, and then used npm to install bower. After spending half my life trying to find the bower folder, if found it in
C:\Users\ME\AppData\Roaming\npm\node_modules\bower
However, I just installed Foundation via Bower and have NO idea where it installed the Foundation files. I assume from my Google searches that it's in the bower_components folder, but I have no idea where that is. I haven't moved it around or done anything abnormal, so I assume it should just be somewhere pretty standard, but I can't find it anywhere! Any pointers on where to look? I have looked this up online a bunch of times, but either this is super obvious so nobody has ever been noob enough to ask it or I'm just bad at Googling my life problems. Is there a command I can run to find out where this is?
It depends. If you are using -g flag when isntalling, it tells npm or bower to install packages globally. It meens you can use them in the whole system and not only for the one project. In this case they are installed into AppData folder, node_modules for npm and bower_components for bower.
On the other hand, if you don't use -g flag, you are installing packages only for the project which you are actually working on. It is simply the folder where you are when you run the install command. Then folders node_packages and bower_components are created in your actual folder and packages are placed into them.
If you install with -g flag, packages will be install globally. But when you download without -g flag, you can change bower package directory with .bowerrc file.
You should create .bowerrc file if not exist, and write this in file.
{
"directory" : "src/components"
}

how to install highcharts with bower

I am starting a new Ember-CLI project. And I want to install HighCharts with bower.
How do I do this?
I have read two posts about this.
The first one tells me to:bower install highcharts.com
Unfortunately the install hangs and eventually crashes
The second post tells me to: bower install https://github.com/highslide-software/highcharts-release
But this only seems to install a bower.json and an index file... but no js files?
In this specific case, can I just manually place the highcharts.js into my own vendor folder... update brocfile and just forget bower for now? Is there any downside to this?
I have found that the unzipping of highcharts.com does take way longer than any other repo, but it should succeed eventually. There is also highcharts-release, which you mentioned. You should be able to just enter the following,
bower install highcharts-release
Once that installs you should have the files highcharts.js and highcharts.src.js at your disposal.
Try using the keyword -- highcharts-release instead of the full path.
highcharts-release contains way fewer files, which should resolve your issue.
If you use your own vendor folder, it will be harder to update to newer releases in the future, I would not recommend it unless using bower is really impossible, which is somewhat doubtful.
Another way to update the bower.json and install it via CLI from the project directory.
bower install

Building c++ project in Ubuntu Linux with Makefile.am/Makefile.in

I am new in Ubuntu/Linux and I've been working with java using the NetBeans IDE, so I don't have much experience with building c++ projects. But now I have to provide a proof of concept and I need to connect a C++ client with my ActiveMQ server. I downloaded The ActiveMQ-CPP API from this link, but I can't build/run it.
The download came with the files: Maklefile.am and Makefile.in. I searched it and I found that I need automake/autoconf to build it. I tried running ./configure but it says that it couldn't find such file or directory. I tried
sudo apt-get update
sudo apt-get install automake
sudo apt-get install autoconf
and a lot of other commands that I found on the Internet. None of then worked. I know that this question is really basic and it seems to be already answered somewhere else, but every attempt I've made failed. I think I'm missing something. I even tried the solution provided in the last message in this topic but it didn't work either.
Can anyone help me install autoconf/automake, or tell me how to use Makefile.am / Makefile.in to build the project I downloaded, or even suggest me some other way of building it?
Since you're open to other methods of building your project, I'm going to suggest CMake. It is a far better build system than autotools (at least from where I stand).
#CMakeLists.txt
project(MyProject CXX)
set_minimum_required(VERSION 2.8)
add_executable(foobar foo.cpp bar.cpp)
That example will build an executable called "foobar" by compiling and linking foo.cpp and bar.cpp. Put the above code in a file called CMakeLists.txt, then run the following commands:
cmake <path to project> #run in the folder you want to build in
make #this does the actual work
The really cool thing about CMake is that it generates a build system (Makefiles by default) but you can use it to generate project files for Eclipse, a Visual Studio solution, and a bunch of other things. If you want more information, I'd check out their documentation.
The "configure" script should be in your ActiveMQ-cpp source directory. From the Linux command line, you should be able to:
1) "cd" into your ActiveMQ* directory
2) "ls -l" to see the "configure" script
3) "./configure" to set things up for building the library\
4) "make" to actually build the library
This is mentioned in comments, but this particular point of confusion has been common for well over a decade and I think needs to be clarified as often as possible. You DO NOT need to have autoconf or automake installed to build a project that used those tools. The entire point of the autotools is to generate a build system that will build on a system using only the standard tools (make, a c compiler, sh, and few others.) Unfortunately, many developers release tarballs that do not build cleanly. If you unpack the tarball and it does not contain a configure script, or if the configure script is broken, that is a bug in the package. The solution is absolutely not to install autoconf/automake/libtool and try to produce a working configure script. The solution is to report the build error as a bug to the package maintainer.
The world would be a better place if Linux distributions stopped installing multiple versions of the autotools by default as less than .002% of the population needs those tools, and anyone who actually needs to have the tools should be capable of installing it themselves. Anyone incapable of acquiring and installing the tools has no business using them.

why can't I to install boost in /usr/include?

I'm trying to install boost into include directory for avoid -I flag use in each g++ compiler call,I installed using this command line: ./bjam --prefix=/usr/include install
see --prefix value, it install in /home/myusername, why?
Thanks in advance.
You would need root permissions to install in /usr/include.
Actually your system has done you a favor by not letting you do that. The --prefix option says where to install everything -- headers, libraries, executables, documentation, etc. For example, the header files would be installed in /usr/include/include, which is not going to be in your compiler's search path.
Disclaimer:: This assume that ./bjam --prefix=... behaves similarly to ./configure --prefix=.... I haven't actually used bjam. If bjam's --prefix option means something else, please correct me.
Depending on your system, you may be able to install Boost from a repository rather than building it from source. For Debian or Ubuntu, for example, something like sudo apt-get install libboost might work.
Note that I said something like that; it appears that Boost consists of a number of packages; apt-cache search boost, or better yet, do a Google search to see how to install Boost on your particular system.
Try running
sudo ./bjam
Doing this should run bjam with appropriate privileges to install to /usr/local/include and /usr/local/lib, both of which should be in your search path...