SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV Github Development

Notices

SageTV Github Development Discussion related to SageTV Open Source Development. Use this forum for development topics about the Open Source versions of SageTV, hosted on Github.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 08-11-2015, 05:35 PM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,539
Build SageTV (Linux Specific) + GitHub primer

GIT
Some GIT CheatSheets

Fork It!
If you are going to make contributions to SageTV you will need a github account (free) and you will need to FORK the SageTV repo. IF you are NOT going to make contributions, and you just want to play with the code, then you don't need to fork it, you can simply clone the google repo, locally.

Step 1: Goto https://github.com/google/sagetv
Step 2: Click the "Fork" at the top/right of the screen.

Basically, you cannot actually commit directly to SageTV, instead, you would make changes in your own repo (or be a member of someone else's) and then commit the changes there, and then submit a Pull Request to have those changes merged into the main SageTV repo. This is a standard Open Source practice.

Get the Code
On Ubuntu, you can install the git command line tools
Code:
sudo apt-get install git
Once you have git installed, AND you have forked the repo, you can get the code by using...

Code:
git clone git@github.com:GITUSER/sagetv.git
where GITUSER is you GitHub userid

For example the sagetv github url is https://github.com/google/sagetv.git

HINT: The GitHub project url is on the right hand side of the GitHub page labelled as "HTTPS Clone URL"


Configure Linux (Ubuntu)

This section assumes that you configuring this manually on your machine, but you can alternatively check out coppit's Docker image or my Vagrant image for ways to automatically provision environments that can be used for development.

First, you need to set the JDK_HOME environment variable to be where your currently installed Java is located. If you are running a 32bit machine, then you NEED the 32bit java. If you are running a 64bit machine then you need the 64bit java.

SageTV requires Java 1.5+. (I'm currently using Java 8)

You can install java 8 in Ubuntu using the following commands.
Code:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install -y oracle-java8-installer
And then set the JDK_HOME
Code:
export JDK_HOME=/usr/lib/jvm/java-8-oracle/
If you are running 32bit linux, then
Code:
export JAVA_ARCH=i386
If you are running 64bit linux, then
Code:
export JAVA_ARCH=amd64
Install these Ubuntu dependencies
Code:
sudo apt-get install libx11-dev libxt-dev libraw1394-dev libavc1394-dev libiec61883-dev libfreetype6-dev yasm autoconf libtool build-essential
Need these for mplayer audio support
Code:
sudo apt-get install libaudio-dev libpulse-dev libasound-dev
NOTE: For now, you can ONLY build the 32bit version of SageTV on a 32bit system, and the 64bit version on a 64bit machine. There is no cross compiling, at the moment.

Building SageTV
Building the entire SageTV project is a easy as navigating to the build directory and running the buildall.sh script.

Code:
cd build
./buildall.sh
NOTE: If you are running Ubuntu 15.10+, mplayer will fail to build. You need to do the following as per this post.
Code:
sudo apt-get install gcc-4.7
cd <build dir>
CC=gcc-4.7 ./buildall.sh
Running SageTV
While you could actually test/run sage by running it from the serverrelease directory, it is not recommeded to do so. A better approach would be to install it using the tar balls and run it from that location.
64 Bit
SageTV is historically a 32bit system. While I compiled it fine on 64bit system, and it did start, I did experience crashes with the MiniClient and the Server (yet to investigate). Jeff feel confident that it should run under 64bit environements, so we'll investigate to see what are the issues.
Keeping Your Forked REPO Up To Date
Make sure you have have Google upstream repo in your remotes

Code:
seans@seans-desktop:~/git/sagetv$ git remote -v
origin	git@github.com:stuckless/sagetv.git (fetch)
origin	git@github.com:stuckless/sagetv.git (push)
upstream	https://github.com/google/sagetv.git (fetch)
upstream	https://github.com/google/sagetv.git (push)
If not then add it
Code:
git remote add upstream https://github.com/google/sagetv.git
Next merge changes from the upstream
Code:
git fetch upstream
git rebase upstream/master
And finally push those changes back into your repo
Code:
git push origin master
The following URLs have more detailed explanations about the above commands
https://help.github.com/articles/con...te-for-a-fork/
https://help.github.com/articles/syncing-a-fork/
https://help.github.com/articles/pushing-to-a-remote/

Building using Docker
If you don't fiddle with setting up dependencies, you an also build sagetv using Docker. See this thread for building using a Docker container.

Last edited by stuckless; 05-18-2016 at 05:34 AM. Reason: Updated with how to build when mplayer fails
Reply With Quote
  #2  
Old 08-11-2015, 06:38 PM
Narflex's Avatar
Narflex Narflex is offline
Sage
 
Join Date: Feb 2003
Location: Redondo Beach, CA
Posts: 6,301
I'd recommend changing the part about cd'ing into the serverrelease directory and running SageTV directly from there. I didn't intend for that to work that way (although it may)...it's better to install it somewhere else using the tarballs and then run from there.

And I noticed you said it crashed on 64 bit Linux...if you can provide more details on why (on another thread), I'd be more than happy to look into it...I'd like to get it working on 64 bit.
__________________
Jeffrey Kardatzke
Google
Founder of SageTV
Reply With Quote
  #3  
Old 08-11-2015, 07:44 PM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,539
Quote:
Originally Posted by Narflex View Post
I'd recommend changing the part about cd'ing into the serverrelease directory and running SageTV directly from there. I didn't intend for that to work that way (although it may)...it's better to install it somewhere else using the tarballs and then run from there.

And I noticed you said it crashed on 64 bit Linux...if you can provide more details on why (on another thread), I'd be more than happy to look into it...I'd like to get it working on 64 bit.
I did very minimal amount of testing, so far, but I'll spend some more time on it and do some cleaner tests. If there are crashes in the JNI layer, is there any logging for that? I'm not too familiar with JNI (I've done some, but I recall troubleshooting it to be very tedious).
Reply With Quote
  #4  
Old 08-11-2015, 08:00 PM
MrD MrD is offline
Sage Aficionado
 
Join Date: Feb 2005
Location: Washington DC
Posts: 387
Quote:
Originally Posted by Narflex View Post
And I noticed you said it crashed on 64 bit Linux...if you can provide more details on why (on another thread), I'd be more than happy to look into it...I'd like to get it working on 64 bit.
For me the placeshifter dies on Ubuntu 15.04 64-bit.

Miniclient.log

Code:
Starting MiniClient
Tue 8/11 18:57:53.834 Detecting cryptography support...
Tue 8/11 18:57:54.080 Starting SageTVPlaceshifter Client
Tue 8/11 18:57:54.095 Attempting to connect to server at localhost:31099
Tue 8/11 18:57:54.115 Connection accepted by server
Tue 8/11 18:57:54.115 Connected to media server
Tue 8/11 18:57:54.118 Connection accepted by server
Tue 8/11 18:57:54.118 Connected to gfx server
Tue 8/11 18:57:54.230 Loaded
Type size error: sizeof(jint) < sizeof(size_t)
Type size error: sizeof(jint) < sizeof(ssize_t)
Type size error: sizeof(jint) < sizeof(ino_t)
Type size error: sizeof(jint) < sizeof(nlink_t)
Type size error: sizeof(jint) < sizeof(blksize_t)
Type size error: sizeof(jint) < sizeof(nfds_t)
Type size error: sizeof(jint) < sizeof(msgqnum_t)
Type size error: sizeof(jint) < sizeof(msglen_t)
Type size error: sizeof(int) < sizeof(ino_t)
Jtux error: Java native types don't match POSIX/SUS types.
Tue 8/11 18:57:54.243 Creating opengl renderer
Tue 8/11 18:57:54.243 Native order: LITTLE_ENDIAN
Tue 8/11 18:57:54.245 Testing to see if server can do a pull mode streaming connection...
Tue 8/11 18:57:54.245 Server can do a pull-mode streaming connection.
Server.log

Code:
Tue 8/11 18:57:54.098 [MiniUIServer@3d481e9f] MiniUI got connection from java.nio.channels.SocketChannel[connected local=/127.0.0.1:31099 remote=/127.0.0.1:56587]
Tue 8/11 18:57:54.114 [MiniUIServerConnection@10f5cab9] MiniPlayer is adding to its map:000c291eb35d
Tue 8/11 18:57:54.115 [MiniUIServer@3d481e9f] MiniUI got connection from java.nio.channels.SocketChannel[connected local=/127.0.0.1:31099 remote=/127.0.0.1:56588]
Tue 8/11 18:57:54.115 [MiniUIServerConnection@10f5cab9] MiniUI is adding to its map:000c291eb35d
Tue 8/11 18:57:54.115 [MiniUIServerConnection@10f5cab9] Creating new UI for client:000c291eb35d
Tue 8/11 18:57:54.116 [MiniUIServerConnection@10f5cab9] Creating-2 new UI for client:000c291eb35d UIManager:localhost@@000c291eb35d-2f346c71
Tue 8/11 18:57:54.244 [MediaServerConnection@51aad373] Error in MediaServerConnection of :java.io.EOFException
Tue 8/11 18:57:54.245 [MediaServerConnection@51aad373] java.io.EOFException
Tue 8/11 18:57:54.245 [MediaServerConnection@51aad373] 	at sage.MediaServer$Connection.readLineBytes(MediaServer.java:239)
Tue 8/11 18:57:54.245 [MediaServerConnection@51aad373] 	at sage.MediaServer$Connection.run(MediaServer.java:956)
Tue 8/11 18:57:54.245 [MediaServerConnection@51aad373] 	at sage.Pooler$PooledThread.run(Pooler.java:252)
Tue 8/11 18:57:54.597 [MiniUIClientReceiver@5f017911] Exception in the MiniUIClientReceiver of: java.io.IOException: Connection reset by peer
Tue 8/11 18:57:54.597 [MiniUIClientReceiver@5f017911] java.io.IOException: Connection reset by peer
Tue 8/11 18:57:54.597 [MiniUIClientReceiver@5f017911] 	at sun.nio.ch.FileDispatcherImpl.read0(Native Method)
Tue 8/11 18:57:54.597 [MiniUIClientReceiver@5f017911] 	at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:39)
Tue 8/11 18:57:54.597 [MiniUIClientReceiver@5f017911] 	at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223)
Tue 8/11 18:57:54.597 [MiniUIClientReceiver@5f017911] 	at sun.nio.ch.IOUtil.read(IOUtil.java:197)
Tue 8/11 18:57:54.597 [MiniUIClientReceiver@5f017911] 	at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:380)
Tue 8/11 18:57:54.597 [MiniUIClientReceiver@5f017911] 	at sage.MiniClientSageRenderer$MiniUIClientReceiver.run(MiniClientSageRenderer.java:8167)
Tue 8/11 18:57:54.598 [KillUIMgr@51aad373] Killing UIMgr UIManager:localhost@@000c291eb35d-2f346c71
Tue 8/11 18:57:54.598 [KillUIMgr@51aad373] Error calling finishWatch from VF goodbye:java.lang.NullPointerException
Tue 8/11 18:57:54.598 [KillUIMgr@51aad373] Killed VideoFrame
Tue 8/11 18:57:54.598 [KillUIMgr@51aad373] Saving properties file to clients/000c291eb35d.properties
Tue 8/11 18:57:54.599 [KillUIMgr@51aad373] Done writing out the data to the properties file
Tue 8/11 18:57:54.600 [KillUIMgr@51aad373] Disposed Window
Tue 8/11 18:57:59.134 [MiniUIServerConnection@10f5cab9] MiniUI established for 000c291eb35d status=false
Tue 8/11 18:57:59.136 [MiniUIServerConnection@10f5cab9] Splash: Rendering Engine is initializing...
Tue 8/11 18:57:59.136 [MiniUIServerConnection@10f5cab9] UIMgr was asynchronously killed during construction, re-destroy it now that init is done
Tue 8/11 18:57:59.136 [MiniUIServerConnection@10f5cab9] Killing UIMgr UIManager:localhost@@000c291eb35d-2f346c71
Tue 8/11 18:57:59.137 [MiniUIServerConnection@10f5cab9] Error calling finishWatch from VF goodbye:java.lang.NullPointerException
Tue 8/11 18:57:59.137 [MiniUIServerConnection@10f5cab9] Killed VideoFrame
Tue 8/11 18:57:59.638 [FinalRender-000c291eb35d@1daad27e] Terminating the BGResourceLoader for the rendering engine
Tue 8/11 18:57:59.640 [FinalRender-000c291eb35d@1daad27e] deinitMini()
Tue 8/11 18:57:59.640 [PluginEventQueue@1495f45d] Core is about to process the event ClientDisconnected vars={MACAddress=000c291eb35d, IPAddress=127.0.0.1}
Tue 8/11 18:58:01.139 [MiniUIServerConnection@10f5cab9] Killed RootPanel
Tue 8/11 18:58:01.139 [MiniUIServerConnection@10f5cab9] Saving properties file to clients/000c291eb35d.properties
Tue 8/11 18:58:01.142 [MiniUIServerConnection@10f5cab9] Done writing out the data to the properties file
Tue 8/11 18:58:01.142 [MiniUIServerConnection@10f5cab9] Disposed Window
Tue 8/11 18:58:24.137 [MiniUIServer@3d481e9f] Dropping old MiniPlayer connection because it's old from:000c291eb35d
I cannot tell if the cause is server side or client side. I suspect the client side.

NB: I have never used the linux place-shifter and I do not currently have access to any windows clients or extenders.
__________________
[size=1]-MrD
=============
Linux Server 7.1.9 (1)HD300 (1) HD200 (1) HD100 (2) PC Clients
Intel Xeon L? 32Gb
CetonTV cable card /FIOS
Reply With Quote
  #5  
Old 08-11-2015, 08:13 PM
Narflex's Avatar
Narflex Narflex is offline
Sage
 
Join Date: Feb 2003
Location: Redondo Beach, CA
Posts: 6,301
The Placeshifter crash I know about. That's because there's .so files for jogl that it's using and it has the 32 bit ones there. Ideally this would be updated to use a different type of JOGL JAR package which contains all the proper native libraries...and I think that's actually available...I just didn't get around to fixing that part....

Anyhoo...to fix your problem, you should just need to download the 64 bit JOGL libraries and replace the ones in the placeshifter folder; then it should work. (I have not verified this myself)
__________________
Jeffrey Kardatzke
Google
Founder of SageTV
Reply With Quote
  #6  
Old 08-12-2015, 07:10 AM
Taddeusz Taddeusz is offline
SageTVaholic
 
Join Date: Nov 2004
Location: Yukon, OK
Posts: 3,922
What are the general memory requirements for the Linux version? Currently running on Windows. Planning on creating a VM on my ESXi server for testing.
__________________
Server: i5 8400, ASUS Prime H370M-Plus/CSM, 16GB RAM, 15TB drive array + 500GB cache, 2 HDHR's, SageTV 9, unRAID 6.6.3
Client 1: HD300 (latest FW), HDMI to an Insignia 65" 1080p LCD and optical SPDIF to a Sony Receiver
Client 2: HD200 (latest FW), HDMI to an Insignia NS-LCD42HD-09 1080p LCD
Reply With Quote
  #7  
Old 08-12-2015, 08:26 AM
wayner wayner is offline
SageTVaholic
 
Join Date: Jan 2008
Location: Toronto, ON
Posts: 6,568
It looks like all of the discussion is currently about Linux. Should those of us that want to start trying Sage be thinking about a Linux install as it looks like that is the favored platform going forward?

If so, what is Linux support like for devices like the 1212 HD-PVR, and USB-UIRT?
__________________
New Server - Sage9 on unRAID 2xHD-PVR, HDHR for OTA
Old Server - Sage7 on Win7Pro-i660CPU with 4.6TB, HD-PVR, HDHR OTA, HVR-1850 OTA
Clients - 2xHD-300, 8xHD-200 Extenders, Client+2xPlaceshifter and a WHS which acts as a backup Sage server
Reply With Quote
  #8  
Old 09-24-2015, 01:44 PM
AtariJeff's Avatar
AtariJeff AtariJeff is offline
Sage Aficionado
 
Join Date: Nov 2005
Location: Ontario, Canada
Posts: 276
Quote:
Originally Posted by stuckless View Post
...
SageTV requires Java 1.5+. (I'm currently using Java 8)

You can install java 8 in Ubuntu using the following commands.
Code:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install -y oracle-java8-installer
...
You may want to update this to say to NOT install Java 8 if you plan on using Jetty Web Services. Java 7 seems to work fine.
Reply With Quote
  #9  
Old 05-17-2016, 06:09 PM
roymcd roymcd is offline
Sage User
 
Join Date: May 2010
Location: Adelaide
Posts: 38
Trying to get hold of or build 32 bit version

Hi
I haven't been able to find a pre-built i386 version of the open source bundle. I've followed stuckless's instructions for building under Ubuntu (I'm using 16.04) on a VM. Things seem to build OK until it fails on MPLAYER because the gcc (5.3.1 20160413) version isn't one used by the mplayer developers. Haven't got the machine up right now, but I think they only supported versions up to 4.x. Does anyone have any advice on this? Anyone else encountered this and found a way through? From the warnings that the configure script gives, it looks like there can be significant problems if you don't use a gcc version that's already been tested by the developers. Currently looking at how to downgrade gcc on the VM:-(
__________________
--------------------------------------------------
Intel Atom 510 2x1.6GHz, 2GB, Ubuntu server 10.10, DViCO FusionHDTV DVB-T Dual Digital 4 (rev 2),
MyGica Dual Tuner USB DVB-T,
2 x HD-200 clients
Reply With Quote
  #10  
Old 05-17-2016, 07:07 PM
Taddeusz Taddeusz is offline
SageTVaholic
 
Join Date: Nov 2004
Location: Yukon, OK
Posts: 3,922
Quote:
Originally Posted by roymcd View Post
Hi
I haven't been able to find a pre-built i386 version of the open source bundle. I've followed stuckless's instructions for building under Ubuntu (I'm using 16.04) on a VM. Things seem to build OK until it fails on MPLAYER because the gcc (5.3.1 20160413) version isn't one used by the mplayer developers. Haven't got the machine up right now, but I think they only supported versions up to 4.x. Does anyone have any advice on this? Anyone else encountered this and found a way through? From the warnings that the configure script gives, it looks like there can be significant problems if you don't use a gcc version that's already been tested by the developers. Currently looking at how to downgrade gcc on the VM:-(
It won't build on Ubuntu versions newer than 15.04.
__________________
Server: i5 8400, ASUS Prime H370M-Plus/CSM, 16GB RAM, 15TB drive array + 500GB cache, 2 HDHR's, SageTV 9, unRAID 6.6.3
Client 1: HD300 (latest FW), HDMI to an Insignia 65" 1080p LCD and optical SPDIF to a Sony Receiver
Client 2: HD200 (latest FW), HDMI to an Insignia NS-LCD42HD-09 1080p LCD
Reply With Quote
  #11  
Old 05-17-2016, 09:38 PM
roymcd roymcd is offline
Sage User
 
Join Date: May 2010
Location: Adelaide
Posts: 38
Quote:
Originally Posted by Taddeusz View Post
It won't build on Ubuntu versions newer than 15.04.
Thanks for the quick response. In the meantime I installed gcc-4.7 via sudo apt-get install gcc-4.7 and the build didn't fail using CC=gcc-4.7 ./buildall.sh. So ATM it looks like a clean build just following stuckless's instructions, with JAVA_ARCH=i386, plus
sudo apt-get install gcc-4.7
cd <build dir>
CC=gcc-4.7 ./buildall.sh


Haven't tried running it yet tho:-)
__________________
--------------------------------------------------
Intel Atom 510 2x1.6GHz, 2GB, Ubuntu server 10.10, DViCO FusionHDTV DVB-T Dual Digital 4 (rev 2),
MyGica Dual Tuner USB DVB-T,
2 x HD-200 clients
Reply With Quote
  #12  
Old 05-18-2016, 05:29 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,539
Quote:
Originally Posted by roymcd View Post
Thanks for the quick response. In the meantime I installed gcc-4.7 via sudo apt-get install gcc-4.7 and the build didn't fail using CC=gcc-4.7 ./buildall.sh. So ATM it looks like a clean build just following stuckless's instructions, with JAVA_ARCH=i386, plus
sudo apt-get install gcc-4.7
cd <build dir>
CC=gcc-4.7 ./buildall.sh


Haven't tried running it yet tho:-)
That is good to know. I currently use a Docker container. But I'll update the main post with a a note about using CC=gcc-4.7
Reply With Quote
  #13  
Old 05-18-2016, 08:57 AM
Taddeusz Taddeusz is offline
SageTVaholic
 
Join Date: Nov 2004
Location: Yukon, OK
Posts: 3,922
Quote:
Originally Posted by roymcd View Post
Thanks for the quick response. In the meantime I installed gcc-4.7 via sudo apt-get install gcc-4.7 and the build didn't fail using CC=gcc-4.7 ./buildall.sh. So ATM it looks like a clean build just following stuckless's instructions, with JAVA_ARCH=i386, plus
sudo apt-get install gcc-4.7
cd <build dir>
CC=gcc-4.7 ./buildall.sh


Haven't tried running it yet tho:-)
Cool. Just ran this and it worked great!

If you don't plan on using the newer gcc you can put CC=gcc-4.7 in /etc/environment and don't have to worry about setting CC every time you want to do a build.
__________________
Server: i5 8400, ASUS Prime H370M-Plus/CSM, 16GB RAM, 15TB drive array + 500GB cache, 2 HDHR's, SageTV 9, unRAID 6.6.3
Client 1: HD300 (latest FW), HDMI to an Insignia 65" 1080p LCD and optical SPDIF to a Sony Receiver
Client 2: HD200 (latest FW), HDMI to an Insignia NS-LCD42HD-09 1080p LCD
Reply With Quote
  #14  
Old 05-18-2016, 05:38 AM
stanger89's Avatar
stanger89 stanger89 is offline
SageTVaholic
 
Join Date: May 2003
Location: Marion, IA
Posts: 15,186
Quote:
Originally Posted by roymcd View Post
Hi
I haven't been able to find a pre-built i386 version of the open source bundle.
You mean like these?
https://bintray.com/opensagetv/saget...9.0.4.252/view

From this sticky in the Open Source Downloads forum:
http://forums.sagetv.com/forums/showthread.php?t=62422
Reply With Quote
  #15  
Old 05-18-2016, 05:56 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,539
Quote:
Originally Posted by stanger89 View Post
You mean like these?
https://bintray.com/opensagetv/saget...9.0.4.252/view

From this sticky in the Open Source Downloads forum:
http://forums.sagetv.com/forums/showthread.php?t=62422
But those are x86_64 (or amd64) versions, not i386, which implies 32bit versions. I don't build 32bit versions... Not sure why anyone would be running 32bit linux, today, to be honest, so I only build 64bit versions.
Reply With Quote
  #16  
Old 05-18-2016, 06:00 AM
stanger89's Avatar
stanger89 stanger89 is offline
SageTVaholic
 
Join Date: May 2003
Location: Marion, IA
Posts: 15,186
I guess I just read i386 as PC/Intel not specifically x86 32.
Reply With Quote
  #17  
Old 05-18-2016, 05:40 PM
roymcd roymcd is offline
Sage User
 
Join Date: May 2010
Location: Adelaide
Posts: 38
Quote:
Originally Posted by stuckless View Post
But those are x86_64 (or amd64) versions, not i386, which implies 32bit versions. I don't build 32bit versions... Not sure why anyone would be running 32bit linux, today, to be honest, so I only build 64bit versions.
My server is a 4-core Atom system that is only 32-bit. I'm currently trying to move SageTV and other services (btsync amongst others) from Ubuntu on this platform to Tiny Core Linux. I'm having some success, although Tiny Core Linux takes a bit of getting used to.
__________________
--------------------------------------------------
Intel Atom 510 2x1.6GHz, 2GB, Ubuntu server 10.10, DViCO FusionHDTV DVB-T Dual Digital 4 (rev 2),
MyGica Dual Tuner USB DVB-T,
2 x HD-200 clients
Reply With Quote
  #18  
Old 08-20-2016, 09:27 PM
vanchie21 vanchie21 is offline
Sage Advanced User
 
Join Date: Oct 2008
Posts: 77
jni.h not found

Ok I'm scratching my head on this. When building in Linux Mint and it get to building the shared libraries I get a fatal error, jni.h not found. Here is all of what I went through:

bobby@bobby-PC ~ $ sudo add-apt-repository ppa:webupd8team/java
[sudo] password for bobby:
You are about to add the following PPA:
Oracle Java (JDK) Installer (automatically downloads and installs Oracle JDK7 / JDK8 / JDK9). There are no actual Java files in this PPA.

More info (and Ubuntu installation instructions):
- for Oracle Java 7: http://www.webupd8.org/2012/01/insta...buntu-via.html
- for Oracle Java 8: http://www.webupd8.org/2012/09/insta...u-via-ppa.html

Debian installation instructions:
- Oracle Java 7: http://www.webupd8.org/2012/06/how-t...in-debian.html
- Oracle Java 8: http://www.webupd8.org/2014/03/how-t...in-debian.html

Oracle Java 9 (for both Ubuntu and Debian): http://www.webupd8.org/2015/02/insta...ntu-linux.html

For JDK9, the PPA uses standard builds from: https://jdk9.java.net/download/ (and not the Jigsaw builds!).

Important!!! For now, you should continue to use Java 8 because Oracle Java 9 is available as an early access release (it should be released in 2016)! You should only use Oracle Java 9 if you explicitly need it, because it may contain bugs and it might not include the latest security patches! Also, some Java options were removed in JDK9, so you may encounter issues with various Java apps. More information and installation instructions (Ubuntu / Linux Mint / Debian): http://www.webupd8.org/2015/02/insta...ntu-linux.html
More info: https://launchpad.net/~webupd8team/+archive/ubuntu/java
Press Enter to continue or Ctrl+C to cancel

Executing: /tmp/tmp.ufywVUGOTz/gpg.1.sh --keyserver
hkp://keyserver.ubuntu.com:80
--recv-keys
EEA14886
gpg: requesting key EEA14886 from hkp server keyserver.ubuntu.com
gpg: key EEA14886: "Launchpad VLC" not changed
gpg: Total number processed: 1
gpg: unchanged: 1
bobby@bobby-PC ~ $ sudo apt-get update
Ign:1 http://packages.linuxmint.com sarah InRelease
Hit:2 http://ppa.launchpad.net/webupd8team/java/ubuntu xenial InRelease
Hit:3 http://archive.ubuntu.com/ubuntu xenial InRelease
Get:4 http://security.ubuntu.com/ubuntu xenial-security InRelease [94.5 kB]
Hit:5 http://packages.linuxmint.com sarah Release
Get:6 http://archive.ubuntu.com/ubuntu xenial-updates InRelease [95.7 kB]
Hit:8 http://archive.canonical.com/ubuntu xenial InRelease
Hit:9 http://archive.ubuntu.com/ubuntu xenial-backports InRelease
Fetched 190 kB in 3s (60.5 kB/s)
Reading package lists... Done
bobby@bobby-PC ~ $ export JDK_HOME=/bobby/lib/jvm/java-8-oracle/
bobby@bobby-PC ~ $ export JAVA_ARCH=i386
bobby@bobby-PC ~ $ cd sagetv
bobby@bobby-PC ~/sagetv $ cd build
bobby@bobby-PC ~/sagetv/build $ ./buildall.sh
Build the Sage.jar file
Bulding Sage.jar...
[ant:exec] The command attribute is deprecated.
Please use the executable attribute and nested arg elements.
:updateBuildNumber
[ant:exec] The command attribute is deprecated.
Please use the executable attribute and nested arg elements.
SAGETV VERSION 9.0.6.347_amd64
:compileJava
Note: /home/bobby/sagetv/java/sage/StudioFrame.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
rocessResources UP-TO-DATE
:classes
:cleanSageJar
:compileTestJava
warning: [options] bootstrap class path not set in conjunction with -source 1.5
warning: [options] source value 1.5 is obsolete and will be removed in a future release
warning: [options] target value 1.5 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
4 warnings
rocessTestResources UP-TO-DATE
:testClasses
:test
:sageJar
Sage.jar created in build/release/
:restoreSageConstants
Restored java/sage/SageConstants.java

BUILD SUCCESSFUL

Total time: 1 mins 8.164 secs
/home/bobby/sagetv/build
Build the Miniclient jar file
[ant:exec] The command attribute is deprecated.
Please use the executable attribute and nested arg elements.
:clean
:cleanMiniJar
:compileMiniclientJava
warning: [options] bootstrap class path not set in conjunction with -source 1.5
warning: [options] source value 1.5 is obsolete and will be removed in a future release
warning: [options] target value 1.5 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
4 warnings
rocessMiniclientResources UP-TO-DATE
:miniclientClasses
:miniclientJar
MiniClient.jar created in build/minirelease/

BUILD SUCCESSFUL

Total time: 11.8 secs
/home/bobby/sagetv/build
Build the shared libraries
make: Entering directory '/home/bobby/sagetv/native/so/SageLinux'
gcc -c -fPIC -I/bobby/lib/jvm/java-8-oracle//include -I/bobby/lib/jvm/java-8-oracle//include/linux -D_FILE_OFFSET_BITS=64 -c -o sage_Sage.o sage_Sage.c
sage_Sage.c:16:17: fatal error: jni.h: No such file or directory
compilation terminated.
<builtin>: recipe for target 'sage_Sage.o' failed
make: *** [sage_Sage.o] Error 1
make: Leaving directory '/home/bobby/sagetv/native/so/SageLinux'
Build failed, exiting.
Build failed, exiting.
I'm just trying sage v 9 out since I can't seem to get the build right on windows. I don't know what I am doing wrong there either. but right now I wanna concentrate on this.
So what am I doing wrong here.
Reply With Quote
  #19  
Old 08-21-2016, 04:40 AM
stuckless's Avatar
stuckless stuckless is offline
SageTVaholic
 
Join Date: Oct 2007
Location: London, Ontario, Canada
Posts: 9,539
Java you set JAVA_HOME and JAVA_ARCH?

You can look at the docker file that I use when building sagetv to get an idea of libraries and environment, etc.

https://github.com/stuckless/sagetv-...r/sagetv-build

EDIT: looks like you are setting it... but /bobby/lib/ doesn't seem right to me. Does that location actually exist?
Reply With Quote
  #20  
Old 08-21-2016, 06:25 AM
vanchie21 vanchie21 is offline
Sage Advanced User
 
Join Date: Oct 2008
Posts: 77
re

Hello struckless,
I hope it does but maybe your right and it doesn't exsits. maybe go and create it then set it to home?
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
I need a YouTube primer Skiier__Dude SageTV Customizations 0 05-30-2012 10:51 AM
Close to building a Linux SageTV Computer, which Linux distribution is best? davephan SageTV Linux 8 02-24-2011 06:57 PM
Can I set SageTV to use a specific Tuner for certain channels? 2FAST4U SageTV Software 1 05-12-2010 06:55 PM
Cable STB primer help requests cavalli Hardware Support 1 12-12-2008 09:27 AM
SageTV Linux specific features ntisdale SageTV Linux 0 04-11-2007 05:12 AM


All times are GMT -6. The time now is 01:16 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.