Hello, On Fri, 18 Aug 2017, Marc Chamberlin wrote:
On 08/18/2017 03:48 PM, David Haller wrote:
On Fri, 18 Aug 2017, Carlos E. R. wrote:
On 2017-08-18 21:56, Marc Chamberlin wrote:
I am attempting to build Bacula (a backup server) from source code and in order to do so, the build configuration for Bacula requires that I give it the path to the source code files for mysql. (or in the case of openSuSE mariadb) I figured out that I could use zypper si mariadb to fetch the source code from the openSuSE repositories. (for some reason YaST is unable to fetch source code packages, which I posted and earlier query about,
See below for that.
Question - If I have to build mariadb from source, is there documentation/instructions on how to do so for Leap42.3?
Just get the source-package, and rpm-rebuild it. But you do not need that for bacula. For bacula, you could have a look at existing builds, e.g.: https://build.opensuse.org/package/show/home%3AXimi1970%3AopenSUSE%3AExtra/b...
David Haller - I am totally impressed that you made such an effort and took the time to try and explain autotools to me. It will take me awhile to grok everything you said but you certainly have me intrigued! I am not sure where you are headed though, are you saying that mariadb/mysql was built using autotools? From my preliminary glance at the source code it seems to me that it was built using cmake. But my eyes are not trained or up to speed on C/C++ build processes any more so take that comment with a chunk of salt!
You're quite correct, it's just that .in files are typical of autotools. But actually, mariadb uses cmake (but got tons of third-party stuff using autotools bundled), and the template is not named config.h.in but config.h.cmake ;) So, instead of "./configure" you'd have to run "cmake ." (just look at the specs of each package for how exactly. Bacula though does use autotools, and I hope my little "rant" helps you to start to understand how _bacula_ is being built. As a user though, you just need to run './configure && make && make DESTDIR=foo install' But when you're building packages, it helps a lot to understand how stuff works, be it autotools, cmake, qmake or whatnot. They all suck.
I guess another way to ask my question is -are you inferring that because there are .h.in files in the mariadb source code directories that mariadb was built using autotools?
Nope. But there's a bunch of sub-dirs and third_party stuff that is build using autotools. Or at least has .in files. Or even .cmake.in... Quite complex stuff.
Or are you saying that I should try and use autotools to create a build process for Bacula?
Nope, it already has one, though the source files (configure.{ac,in} etc.) are moved off to the './autoconf/' subdir of the sources. E.g.: bacula-9.0.3/autoconf/config.h.in bacula-9.0.3/autoconf/configure.in etc. And I don't think you actually need the mariadb source, just all the -devel packages (including mysql.h and mysql_version.h). libmysqlclient18-10.0.30-21.1.x86_64 libmysqlclient-devel-10.0.30-21.1.x86_64 libmysqlclient_r18-10.0.30-21.1.x86_64 I've just tried, I got the home:Ximi1970:openSUSE:Extra/bacula package, added the current bacula-9.0.3.tar.gz, changed the version in the bacula.spec to 9.0.3 and ran 'osc build ...' for 42.3... Built just fine. I haven't looked at anything more in the .spec file, there might be some more work in order ;) Yeah right, e.g. dvd-handler is not installed anymore, and stuff is installed but not packaged. No idea what it's all for, so I just stuffed it in the -common package, just so _those_ packaging errors are "ignored", but those should be properly looked over, so I don't mail these changes. And, lo and behold, except that "mispackaging" I just mentioned, the package builds (not the first build, but with "--no-init" and "ccache" active, that's why it's so fast ;) [ 78s] 11 packages and 0 specfiles checked; 0 errors, 121 warnings. $ ls -1 /data/build/openSUSE_Leap_42.3-x86_64-root/home/abuild/rpmbild/RPMS/x86_64/ bacula-client-9.0.3-1.x86_64.rpm bacula-common-9.0.3-1.x86_64.rpm bacula-console-9.0.3-1.x86_64.rpm bacula-console-bat-9.0.3-1.x86_64.rpm bacula-director-9.0.3-1.x86_64.rpm bacula-lang-9.0.3-1.x86_64.rpm bacula-mysql-9.0.3-1.x86_64.rpm bacula-postgresql-9.0.3-1.x86_64.rpm bacula-sqlite3-9.0.3-1.x86_64.rpm bacula-storage-9.0.3-1.x86_64.rpm For all the nitty gritty details of properly packaging these new/non-installed files right, I'd say asking on opensuse-packaging is in order, and/or expressly ask Ximi1970 for assistance. Maybe you two can maintain the package together ... Anyway, your problems have nothing to do with not having the mariadb sources (and those configured via calling 'cmake')... Feel free to ask on -packaging, for details about the bacula stuff, but also about build-systems like autotools, cmake etc. generally... HTH, -dnh -- If you're looking for me, I'll be the quivering pile of jelly wobbling pitifully in the corner over there. -- Stuart Lamble -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org