Author Topic: Building a dev environment for 0704?  (Read 2851 times)

tschak909

  • LinuxMCE God
  • ****
  • Posts: 5495
  • DOES work for LinuxMCE.
    • View Profile
Building a dev environment for 0704?
« on: October 20, 2007, 09:02:18 pm »
Has anyone successfully set up an environment to build plugins/devices etc for the current LinuxMCE/Pluto? I am currently having difficulty with building DCEGen, it can't find libmysqlclient_r .. which is odd, because it's in the search path....

-Thom

PeteK

  • Guru
  • ****
  • Posts: 408
    • View Profile
Re: Building a dev environment for 0704?
« Reply #1 on: October 20, 2007, 09:17:05 pm »
I've been building a few plugins (namely Z-wave and my Insteon plugin).  Once I followed Paul's instructions here, I was able to build individual plugins OK.

I'll look into more.  But in case this helps, what I do to compile is untar the file to /home/source.  Then cp /usr/pluto/lib/* /home/source/src/lib/

Then: export SNR_CPPFLAGS = "-DKDE_LMCE -DDEBUG -DTHREAD_LOG -DLOG_ALL_QUERIES -I/opt/libxine1-pluto/include -I/opt/libsdl1.2-1.2.7+1.2.8cvs20041007/include -I/opt/libsdl1.2-1.2.7+1.2.8cvs20041007/include/SD"
export SNR_LDFLAGS = "-L/opt/libxine1-pluto/lib -L/opt/libsdl1.2-1.2.7+1.2.8cvs20041007/lib"

then cd to one of the binary directories, like cd /home/source/src/App_Server, and run: make clean bin
or cd to one of the plugins, like cd /home/source/src/Media_Plugin, and run: make clean so

Then I edit the files locally and recompile as needed.  To test it, I either (a) copy the output to /usr/pluto/bin (backup the original file first), (b) make a symlinc in /usr/pluto/bin point ot my output directory, or (c) kill the screen session that's running the device and run it manually from the source directory with: [binary name] -d [device id] -r dcerouter

I'll work on coming up with a clean set of instructions to build all the code and packages from that tar ball.  It is the correct set of sources afaik.

Zaerc

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 2256
  • Department of Redundancy Department.
    • View Profile
Re: Building a dev environment for 0704?
« Reply #2 on: October 20, 2007, 10:23:00 pm »
God forbid people should read the rest of that thread...  ::)
« Last Edit: October 21, 2007, 03:43:52 pm by Zaerc »
"Change is inevitable. Progress is optional."
-- Anonymous


tschak909

  • LinuxMCE God
  • ****
  • Posts: 5495
  • DOES work for LinuxMCE.
    • View Profile
Re: Building a dev environment for 0704?
« Reply #3 on: October 21, 2007, 07:30:14 am »
oddly enough, even following those instructions, I still get:

Code: [Select]

dcerouter_39315:/home/src/LinuxMCE-1.1-SRC/src/DCEGen# apt-get install libmysqlclient15-dev
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.

Since you only requested a single operation it is extremely likely that
the package is simply not installable and a bug report against
that package should be filed.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
  libmysqlclient15-dev: Depends: libmysqlclient15off (>= 5.0.38-0ubuntu1.1) but 5.0.38-0ubuntu1 is to be installed
E: Broken packages
dcerouter_39315:/home/src/LinuxMCE-1.1-SRC/src/DCEGen#


-Thom

Zaerc

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 2256
  • Department of Redundancy Department.
    • View Profile
Re: Building a dev environment for 0704?
« Reply #4 on: October 21, 2007, 04:15:57 pm »
Somehow I seem to have managed to install it on the older core I was using to build on:
Code: [Select]
dpkg -l
...
ii  libmysqlclient15-dev                       5.0.38-0ubuntu1                 
          mysql database development files
ii  libmysqlclient15off                        5.0.38-0ubuntu1                 
          mysql database client library
...
Maybe the package repository got updated in the mean time?
"Change is inevitable. Progress is optional."
-- Anonymous


tschak909

  • LinuxMCE God
  • ****
  • Posts: 5495
  • DOES work for LinuxMCE.
    • View Profile
Re: Building a dev environment for 0704?
« Reply #5 on: October 21, 2007, 05:38:49 pm »
i'm afraid of touching my apt repo because it has had a tendency to break my core when i do.

-Thom

danielk

  • Guru
  • ****
  • Posts: 153
    • View Profile
Re: Building a dev environment for 0704?
« Reply #6 on: October 25, 2007, 12:36:48 am »
I added some hacks to Install_Build_Needed_Packages to get libmysqlclient15-dev installed.

just get the sources at svn.charonmedia.org and type:

./configure
make install_dev_packages

Alternatively, you can inspect src/Ubuntu_Helpers/BuildUbuntu_Functions.sh and look at the Install_Build_Needed_Packages function. The hack I made may not be the best hack. It might be better to force a specific libmysqlclient15-dev package, rather than specific libmysqlclient15off and mysql-common packages. For an example, see libvorbis-dev, where I forced a specific libvorbis-dev version rather than upgrading the underlying library.

Zaerc

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 2256
  • Department of Redundancy Department.
    • View Profile
Re: Building a dev environment for 0704?
« Reply #7 on: December 15, 2007, 08:26:01 pm »
Just in case anyone is still troubled by this problem, here's how I've just fixed it:

Code: [Select]
wget http://security.ubuntu.com/ubuntu/pool/main/m/mysql-dfsg-5.0/mysql-common_5.0.38-0ubuntu1.1_all.deb
dpkg -i mysql-common_5.0.38-0ubuntu1.1_all.deb

wget http://security.ubuntu.com/ubuntu/pool/main/m/mysql-dfsg-5.0/libmysqlclient15off_5.0.38-0ubuntu1.1_i386.deb
dpkg -i libmysqlclient15off_5.0.38-0ubuntu1.1_i386.deb

apt-get install libmysqlclient15-dev

Additionally I had to do a final "apt-get -f install" probably because I tried to install "libmysqlclient15-dev" with "dpkg" earlier.

"Change is inevitable. Progress is optional."
-- Anonymous