LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices



Reply
 
Search this Thread
Old 09-01-2012, 07:46 PM   #1
D1ver
Member
 
Registered: Jan 2010
Distribution: Slackware 13.37
Posts: 527
Blog Entries: 3

Rep: Reputation: 126Reputation: 126
Modem Manager on -current/14.0


Edit: sigh.. Here is where I commit the 'grep -i' command to memory and skulk away with my tail between my legs. Modem manager is included by default and I am just bad a searching..





The slackbuild for Modem Manager for 13.37 (and using the -current git repo for Sbopkg) doesn't work on 14.0. It fails with the error
Code:
error: #error "Only <glib.h> can be included directly."
Which Pat himself says can be fixed by
Quote:
Find in the software that isn't compiling any #include <glib/*.h> and replace it with #include <glib.h> and you should be good to go.
So I went about trying to fix this. I don't have much experience with this sort of thing but hopefully it will help someone.

The patch for the source is as follows
Code:
diff -cr ModemManager-0.5/src/mm-at-serial-port.h ModemManager-0.5-patch/src/mm-at-serial-port.h
*** ModemManager-0.5/src/mm-at-serial-port.h	2010-03-16 04:27:14.000000000 +1100
--- ModemManager-0.5-patch/src/mm-at-serial-port.h	2012-09-02 08:45:38.135016688 +1000
***************
*** 18,24 ****
  #define MM_AT_SERIAL_PORT_H
  
  #include <glib.h>
! #include <glib/gtypes.h>
  #include <glib-object.h>
  
  #include "mm-serial-port.h"
--- 18,24 ----
  #define MM_AT_SERIAL_PORT_H
  
  #include <glib.h>
! //#include <glib/gtypes.h>
  #include <glib-object.h>
  
  #include "mm-serial-port.h"
diff -cr ModemManager-0.5/src/mm-manager.h ModemManager-0.5-patch/src/mm-manager.h
*** ModemManager-0.5/src/mm-manager.h	2010-03-23 09:32:31.000000000 +1100
--- ModemManager-0.5-patch/src/mm-manager.h	2012-09-02 08:46:15.027015531 +1000
***************
*** 17,23 ****
  #ifndef MM_MANAGER_H
  #define MM_MANAGER_H
  
! #include <glib/gtypes.h>
  #include <glib-object.h>
  #include <dbus/dbus-glib.h>
  #include "mm-modem.h"
--- 17,24 ----
  #ifndef MM_MANAGER_H
  #define MM_MANAGER_H
  
! //#include <glib/gtypes.h>
! #include <glib.h>
  #include <glib-object.h>
  #include <dbus/dbus-glib.h>
  #include "mm-modem.h"
diff -cr ModemManager-0.5/src/mm-modem-base.h ModemManager-0.5-patch/src/mm-modem-base.h
*** ModemManager-0.5/src/mm-modem-base.h	2011-08-03 12:58:44.000000000 +1000
--- ModemManager-0.5-patch/src/mm-modem-base.h	2012-09-02 08:46:36.453014859 +1000
***************
*** 18,24 ****
  #define MM_MODEM_BASE_H
  
  #include <glib.h>
! #include <glib/gtypes.h>
  #include <glib-object.h>
  
  #include "mm-port.h"
--- 18,24 ----
  #define MM_MODEM_BASE_H
  
  #include <glib.h>
! //#include <glib/gtypes.h>
  #include <glib-object.h>
  
  #include "mm-port.h"
diff -cr ModemManager-0.5/src/mm-plugin-base.h ModemManager-0.5-patch/src/mm-plugin-base.h
*** ModemManager-0.5/src/mm-plugin-base.h	2011-08-03 12:58:44.000000000 +1000
--- ModemManager-0.5-patch/src/mm-plugin-base.h	2012-09-02 08:46:54.722014286 +1000
***************
*** 17,23 ****
  #define MM_PLUGIN_BASE_H
  
  #include <glib.h>
! #include <glib/gtypes.h>
  #include <glib-object.h>
  
  #define G_UDEV_API_IS_SUBJECT_TO_CHANGE
--- 17,23 ----
  #define MM_PLUGIN_BASE_H
  
  #include <glib.h>
! //#include <glib/gtypes.h>
  #include <glib-object.h>
  
  #define G_UDEV_API_IS_SUBJECT_TO_CHANGE
diff -cr ModemManager-0.5/src/mm-port.h ModemManager-0.5-patch/src/mm-port.h
*** ModemManager-0.5/src/mm-port.h	2011-08-03 12:53:33.000000000 +1000
--- ModemManager-0.5-patch/src/mm-port.h	2012-09-02 08:47:11.871013748 +1000
***************
*** 17,23 ****
  #define MM_PORT_H
  
  #include <glib.h>
! #include <glib/gtypes.h>
  #include <glib-object.h>
  
  typedef enum {
--- 17,23 ----
  #define MM_PORT_H
  
  #include <glib.h>
! //#include <glib/gtypes.h>
  #include <glib-object.h>
  
  typedef enum {
diff -cr ModemManager-0.5/src/mm-qcdm-serial-port.h ModemManager-0.5-patch/src/mm-qcdm-serial-port.h
*** ModemManager-0.5/src/mm-qcdm-serial-port.h	2011-03-25 04:14:31.000000000 +1100
--- ModemManager-0.5-patch/src/mm-qcdm-serial-port.h	2012-09-02 08:47:34.040013053 +1000
***************
*** 18,24 ****
  #define MM_QCDM_SERIAL_PORT_H
  
  #include <glib.h>
! #include <glib/gtypes.h>
  #include <glib-object.h>
  
  #include "mm-serial-port.h"
--- 18,24 ----
  #define MM_QCDM_SERIAL_PORT_H
  
  #include <glib.h>
! //#include <glib/gtypes.h>
  #include <glib-object.h>
  
  #include "mm-serial-port.h"
diff -cr ModemManager-0.5/src/mm-serial-port.h ModemManager-0.5-patch/src/mm-serial-port.h
*** ModemManager-0.5/src/mm-serial-port.h	2011-08-03 12:58:44.000000000 +1000
--- ModemManager-0.5-patch/src/mm-serial-port.h	2012-09-02 08:47:56.746012341 +1000
***************
*** 18,24 ****
  #define MM_SERIAL_PORT_H
  
  #include <glib.h>
! #include <glib/gtypes.h>
  #include <glib-object.h>
  
  #include "mm-port.h"
--- 18,24 ----
  #define MM_SERIAL_PORT_H
  
  #include <glib.h>
! //#include <glib/gtypes.h>
  #include <glib-object.h>
  
  #include "mm-port.h"

And the patch for the slackbuild is
Code:
*** ModemManager.SlackBuild	2012-09-02 09:39:20.354960902 +1000
--- ModemManager.patched.Slackbuild	2012-09-02 09:39:10.225961329 +1000
***************
*** 61,66 ****
--- 61,67 ----
  cd $TMP
  rm -rf $PRGNAM-$VERSION
  tar xvf $CWD/$PRGNAM-$VERSION.tar.xz
+ patch -p0 < $CWD/mm-glib.patch
  cd $PRGNAM-$VERSION
  chown -R root:root .
  find . \
It now builds correctly, and seems to work. I don't know if this fix is of the quality to be included or submitted anywhere, but hopefully it helps someone. If changes need to be made I'm still learning and would like to hear about them
Attached Files
File Type: txt mm-glib.patch.txt (3.9 KB, 0 views)
File Type: txt ModemManager.SlackBuild.patch.txt (346 Bytes, 0 views)

Last edited by D1ver; 09-01-2012 at 08:19 PM. Reason: doh..
 
Old 09-01-2012, 08:22 PM   #2
D1ver
Member
 
Registered: Jan 2010
Distribution: Slackware 13.37
Posts: 527
Blog Entries: 3

Original Poster
Rep: Reputation: 126Reputation: 126
My mistake.. I didn't ignore case on my search for ModemManager, so I missed the fact it's installed by default..


Doh. At least I learned how to make a patch for a slackbuild I suppose.


/embarrassed..
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Money Manager EX on -current BCarey Slackware 5 06-22-2012 11:20 AM
[SOLVED] Issue With Package Manager in -Current jedick Slackware 34 04-08-2011 04:26 AM
[SOLVED] Slim login manager in -Current piratesmack Slackware 9 03-04-2010 07:31 PM
disable current window manager sumeet inani Linux - Newbie 12 04-26-2009 04:18 PM
Slack-Current-01 - HP Device Manager slackass Slackware 7 04-08-2008 08:59 AM


All times are GMT -5. The time now is 05:32 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration