how to only build libsmbclient-raw.so - samba

I only need to build libsmbclient-raw.so in samba. I don't need any other tool or daemon in samba package. The samba version I am working on is samba-4.1.13.
How can I only build libsmbclient-raw.so ?

Run configure as normal. After that, run:
% make bin/shared/libsmbclient-raw.so.0
libsmbclient-raw.so should just be a symlink to libsmbclient-raw.so.0
Note that building libsmbclient-raw.so will pull in a lot of other code, so it will not be that much faster than building all of Samba.

Related

FreePascal & OpenShift

any one has experience with Open Shift and install FreePascal as a cartridge?
I found this but I don't know how make it work :
https://github.com/jhadvig/openshift-pascal-cartridge
I want to know what is the instruction of making FreePascal cartridge.
The following command should install that cartridge for you
rhc app create freepascal https://cartreflect-claytondev.rhcloud.com/reflect?github=jhadvig/openshift-pascal-cartridge
Basically since the manifest.yml file does not contain a Source-Url definition, you need to run it through the cartridge reflector as i did above.
Unfortunately that cartridge also does not seem to install correctly. You should leave an "issue" using the issues tab on that cartridge asking if it is ready for production use or not.
If you want to develop your own cartridge, you can read through the cartridge developers guide here: http://openshift.github.io/documentation/oo_cartridge_developers_guide.html

How to change qemu-kvm version on Eucalyptus cloud-in-a-box?

I am trying to use libvmi tool on KVM virtual machine running on Eucalyptus cloud. It is a cloud-in-a-box 3.4.2 version. To use libvmi on KVM, it requires me to change the qemu-kvm that Eucalyptus by default uses. So I did a patch to the qemu-kvm-1.2.0 source code, compiled it and "make && make install" as this web page said: https://github.com/bdpayne/libvmi/tree/master/tools/qemu-kvm-patch.
Now I need to make sure my system will use this newly installed version of qemu-kvm when running KVM virtual machines. Could anyone tell me how to setup so that Eucalyptus would use my newly-installed qemu-kvm when launching new instances?
I tried "yum erase qemu-kvm", hoping to erase the original version of qemu-kvm so that maybe Eucalyptus would have to use the qemu I just compiled and installed. However when I used "yum erase qemu-kvm", it said "eucalyptus-nc" would also need to be erased for depedency reason, so I didn't continue.
Any help would be appreciated. Thank you very much.
I guess you have a couple options:
Tell configure to install into location used by the packaged installation (perhaps something like ./configure --prefix=/).
Find the qemu-kvm binary on the system and overwrite it with the binary produced in the source tree during compilation.
A backup may help, but then you can always reinstall from packages.

How to setup supervisord on Elastic Beanstalk?

I am migrating from DotCloud to Elastic Beanstalk.
Using DotCloud, they clearly explained how to set up Python Worker, and how to use supervisord.
Moving to Elastic Beanstalk, I am lost on how I could do that.
I have a script myworker.py and want to make sure it is always running. How?
Elastic Beanstalk is just a stack configuration tools over EC2, ELB and autoscaling.
One approach you can use, is create your own AMI, but since October last year, there is another approach that probably will be more suitable for your needs: ebextensions.
.ebextension is just a directory in your application, that get's detected once your application has been loaded by AWS.
Here is the full documentation: http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/customize-containers.html
With Amazon Linux 2 you need to use the .platform folder to supply elastic beanstalk with installation scripts.
We recommend using platform hooks to run custom code on your environment instances. You can still use commands and container commands in .ebextensions configuration files, but they aren't as easy to work with. For example, writing command scripts inside a YAML file can be cumbersome and difficult to test.
So you should add a prebuild hook (example) into a .platform folder to install supervisor and a postdeploy hook (example) to restart supervisor after each deployment.
There is an ini file (example) used in the script; which is made for laravel specific.
Make sure that the .sh files from the .platform folder are executable before deploying your project:
$ chmod +x .platform/hooks/prebuild/*.sh
$ chmod +x .platform/hooks/postdeploy/*.sh

Run a task before svn check-out

I would like to run a task (stop a running vm machine) before Jenkins starts the check-out.
The reason is: VM blocks access to some files I have to update via subversion.
Is this possible?
There are two plugins for controlling virtual machines, depending on whether you are using VirtualBox or VMWare.
I'm quite sure you can configure the pre-build step to be "Suspend" as shown in the images, at least for VMWare.
VMware Plugin
VirtualBox Plugin
Edit your project and set:
Configure M2 Extra Build Steps --> Execute shell --> Type in whatever you'd like to do. For example:
# Wipe the local repository before each build.
rm -rf $WORKSPACE/.repository
Have a look at How do I trigger another job from hudson as a pre-build step?. I think this has been asked before there.

Analyze source code with sonar

It is possible to take the source code directly from a svn repository and analyze it with sonar? Or configure sonar just to run a Checkstyle or pmd plugin for certain sources?
I need to do this on non-maven projects.
Sonar can run without maven entirely. Now there's sonar-runner
Yes, you just need to write a maven or ant script to check out the latest from SVN first, then run the sonar:sonar command.
It looks like Sonar forces you to create a pom.xml file and install maven2, even for a non-mavenized project: http://docs.sonarqube.org/display/SONAR/Analyzing+Source+Code
(fyi - Sonar is dead easy with a mavenized project, but in any setup the key will be in getting in the habit of looking at and using the results of Sonar to improve development. That's the hard part.)