MySQL-Connector

Hi Dan,

      I have a MacBook (Intel)circa 2006 that originally had OS X 10.4
installed. It has 2 GB RAM and is 32 bit. I have installed Ubuntu 12.04.
Could this be used to compile a connector? If so, what has to be done to
do so? I really have no knowledge of any of the computer languages, so I
don't know if my offer to help will be useful.

Yes, that could be used, but you need to compile the whole of LO in
order to get the connector. If you are using the Ubuntu 12.04 (which is
the same baseline as what I have on 32 bit OS), then there is a page on
the developer wiki which tells you what you need to have in order to be
able to build the basic LO on Ubuntu systems.

      I went to the developer wiki. That led me to
http://download.documentfoundation.org/libreoffice/src/4.0.0/. So far so good. But what package do I download to build? I am downloading libreoffice-4.0.0.3.tar.xz <http://download.documentfoundation.org/libreoffice/src/4.0.0/libreoffice-4.0.0.3.tar.xz> just in case that is the correct one. (I don't think that the one labelled translations would be the one.

In addition, you will need libmysqlclient, and libmysqlcppconn. I think
these are installed if you install the mysql connector plugin that
Ubuntu provides with its own distrib version of LO, if not, you will
have to install them via apt-get, synaptic, or the graphical interface
that Ubuntu provides for installing new software (I forget what it is
called at the moment).

  I have one of them had already been installed, so I installed the other one. I also downloaded the dev version of both of this as they might come in handy. If not let me know.

With that hardware, it will take some time, plan on 24-48 hours for a
first build and to have the connector built at the same time, you need
to add the following switches after you type ./autogen.sh to start the
configuration of the build :

--with-ext-mysql-connector --with-system-mysql

If you get an error at this point, give me a shout.

Alex

      Let me see if I understand: 24-48 hours to build LO from the tar ball and after that another 24-48 hours to build the connector. Or is it 24-48 hours to do all of it?

--Dan

"However, the differences in code trees between LO and AOO now mean that the
connector for AOO no longer works in LO4, or at least, that is what Heinrich
has reported (and Robert too, I believe). - Alex"

Just a note to say the AOO native MySQL connector here
<http://http://extensions.openoffice.org/en/project/mysql_connector> DOES
seem to WORK on my Mac (OS X 10.6) with LO Version 4.0.0.3 (tables show up,
queries run) - but I haven't done much testing so far.

Hi Dan,

      I have a MacBook (Intel)circa 2006 that originally had OS X 10.4
installed. It has 2 GB RAM and is 32 bit. I have installed Ubuntu 12.04.
Could this be used to compile a connector? If so, what has to be done to
do so? I really have no knowledge of any of the computer languages, so I
don't know if my offer to help will be useful.

Yes, that could be used, but you need to compile the whole of LO in
order to get the connector. If you are using the Ubuntu 12.04 (which is
the same baseline as what I have on 32 bit OS), then there is a page on
the developer wiki which tells you what you need to have in order to be
able to build the basic LO on Ubuntu systems.

In addition, you will need libmysqlclient, and libmysqlcppconn. I think
these are installed if you install the mysql connector plugin that
Ubuntu provides with its own distrib version of LO, if not, you will
have to install them via apt-get, synaptic, or the graphical interface
that Ubuntu provides for installing new software (I forget what it is
called at the moment).

With that hardware, it will take some time, plan on 24-48 hours for a
first build and to have the connector built at the same time, you need
to add the following switches after you type ./autogen.sh to start the
configuration of the build :

--with-ext-mysql-connector --with-system-mysql

If you get an error at this point, give me a shout.

Alex

Steps taken so far:
1) Used synaptic to download libmysqlclient and libmysqlcppconn. I also downloaded the dev version of these.
2) |sudo apt-get build-dep libreoffice # Debian & derivatives|

3) sudo apt-get install git

4) |||||git clone git://gerrit.libreoffice.org/core libo
5) ||./autogen.sh||--with-ext-mysql-connector --with-system-mysql ||
Some comments: #4 was a very large download. What is in it? (the master build is this large???) On #5, I found the purpose for each of the switches, and I understand their purposes. I have mysql installed on my laptop that I will use to build the connector. So, the mysql config files should have the location to the executable file. For what it is worth, I have 3.5 GB of SWAP on my hard drive.
      As of the time I am sending this email, I am entering #5 into a terminal. I will keep you abreast of my progress.

--Dan

Hi Dan,

> Steps taken so far:

1) Used synaptic to download libmysqlclient and libmysqlcppconn. I also
downloaded the dev version of these.
2) |sudo apt-get build-dep libreoffice # Debian & derivatives|
>3) sudo apt-get install git
4) |||||git clone git://gerrit.libreoffice.org/core libo
5) ||./autogen.sh||--with-ext-mysql-connector --with-system-mysql ||
Some comments: #4 was a very large download. What is in it? (the master

Yes, that is normal, you have downloaded the whole source code tree for the current master build version of LO. In core/libo, you will find a series of folders, each one corresponding to different parts of LO that are either systematically built, or else are optional build modules for some of the extensions or other goodies.

build is this large???) On #5, I found the purpose for each of the
switches, and I understand their purposes. I have mysql installed on my
laptop that I will use to build the connector. So, the mysql config
files should have the location to the executable file. For what it is
worth, I have 3.5 GB of SWAP on my hard drive.
      As of the time I am sending this email, I am entering #5 into a
terminal. I will keep you abreast of my progress.

Good effort so far, now all you have to do is wait :-))
The total time for building LO the first time, including the connector, with a config like the one you mention, is about 24 hours. Seeing as you are only building the mysql connector in addition to the standard extensions, it might be shorter. I regularly build with more extensions (extra templates, extra gallery, googledocs, etc) so it takes more time on my machines.

Alex

My very first problem: (Line 201 of autogen.sh): here is the error

checking for GCONF... yes
checking whether to enable GNOME VFS support... yes
checking for GNOMEVFS... no
configure: error: Package requirements (gnome-vfs-2.0 >= 2.6.0 ) were not met:
No package 'gnome-vfs-2.0' found

      I included the line about GCONF because that is the last line that is good. The next line seems to involve pkg-config which is only in line 36 of autogen.sh. Perhaps line 36 should have # at the beginning to change the line to a Remark. (Yes, I searched the file for pkg-config.)
      So, what do I do to correct this?

--Dan

Hi :slight_smile:
Ouch.  I think this is waay beyond me then.  I just wish i could grant Vpn access to one or 2 of my works machines and then sneakily leave them on by mistake.  It's just not possible though. 
Regards from
Tom :slight_smile:

Hi Dan,

checking for GCONF... yes
checking whether to enable GNOME VFS support... yes
checking for GNOMEVFS... no
configure: error: Package requirements (gnome-vfs-2.0 >= 2.6.0 ) were
not met:
No package 'gnome-vfs-2.0' found

As you found out yourself, you need to install a whole load of Gnome VFS
libraries. Quite why, on Ubuntu, this isn't pulled in with the build-dep
script, I really don't know, an oversight on the Ubuntu developers part,
I guess.

Alex

Some very good news!!! ... and some questions.
      Last evening, I deleted the libo folder and basically began again using git. I let "make" run overnight. This morning, I accidentally ran "make install" getting an error message of not being able to create a folder in /usr/... . So, I used "sudo make install" instead. The build was installed in /usr/lib/... . So, being curious, I tried "sudo make install" instead. The build was installed within the solver folder as it should be. I made ooenv executable and ran it. Since then I have run soffice and looked at Help > About LibreOffice. I now have my own alpha build number!
      One further test: I ran Base in my new LO-DEV opening MySQL.odb which connects to my MySQL server. (This is a copy of the file I use to connect to MySQL. So, if it becomes corrupted, I still have the original database file.) I successfully connected to the MySQL server.
      Again because I was curious, I looked at the libreoffice configuration folder, specifically the extension folder. It contained buildid file which contained a number. I checked this number against the build number of my new Alpha version. They matched.
     It appears that I have created an alpha version of the MySQL native connector. So where is this connector in the extension folder? What is the next step to convert it into the .oxt final version?

--Dan

Hi :slight_smile:
WoooHooo!!  Congrats!  That is really quite awesome to hear about :slight_smile:
Congrats and regards from
Tom :slight_smile: