How to : Oscam compile tutorial

There are 7 replies in this Thread which was already clicked 14,736 times. The last Post () by newtolinux.

  • IN TERMINAL AS ROOT USER TYPE THE FOLLOWING COMMANDS


    FIRST INSTALL REQUIRED PACKAGES
    apt-get install proftpd gcc g++ make cmake bzip2 libpcsclite1 libpcsclite-dev subversion
    OR
    apt-get install gcc g++ cmake libpcsclite1 libpcsclite-dev subversion


    NEXT DRIVERS DOWNLOAD FOR USB DEVICES
    cd /usr/src
    wget Download libusb from SourceForge.net
    tar xjvf libusb-1.0.8.tar.bz2 (if you missing bzip2 then - apt-get install bzip2 and repeat previous command)
    cd libusb-1.0.8
    ./configure --enable-shared=no
    make (if command not found then - apt-get install make and repeat previous command)
    make install


    NOW WE DOWNLOAD OSCAM SOURCES AND COMPILE
    cd /usr/src
    svn co oscam - Revision 4971: /trunk oscam
    cd oscam
    mkdir buid
    cd build
    cmake .. (those two dots important, if WEBIF is wanted then - cmake -DWEBIF=1 ..)
    (if command not found then - apt-get install cmake and repeat previous command)
    make


    NOW WE WILL COPY OSCAM TO /USR/LOCAL/BIN
    cp oscam /usr/local/bin
    cd /usr/local/bin
    ls
    (oscam should be listed here. Next: )
    chmod 755 oscam


    (Before you start the server make sure you got all 3 oscam config files in /usr/local/etc directory.)


    (Don't delete compiling directories, so you can later easily update your oscam version)


    TO COMPILE LATEST VERSION NEXT TIME
    cd /usr/src
    svn co oscam - Revision 4971: /trunk oscam
    cd /usr/src/oscam/build
    cmake ..
    make


    Hope it helps


    regards


    t

    Dont forget to hit the thanks button!!!!!!!!!!!!!



    :41_002:



    Some articles may discuss topics that are illegal, so this information is provided for educational purposes only, your use of the content, downloads and files, or any part thereof, is made solely at your own risk and responsibility. Viewing Pay TV without a valid subscription is illegal. !! Linuxsat-Support.com cannot be held responsible for the content of any information stored or posted on this forum.

  • If you need to re-complie Oscam, first delete all files from the build directory - otherwise Oscam won't re-compile.
    Also, you can determine which modules are compiled using the config.sh shell in the oscam-svn directory (dvapi etc.)
    sudo sh config.sh

  • As long as you are using one of the latest builds the following modules are automatic : -


    Active modules:
    Webif support: yes
    OpenSSL support: no
    Dvbapi support: no
    Anticasc support: yes
    ECM doublecheck: no
    Irdeto guessing: yes
    Debug: yes
    LED support: no
    Qboxhd-LED support: no
    Log history: yes
    Monitor: yes
    Camd33: yes
    Camd35 UDP: yes
    Camd35 TCP: yes
    Newcamd: yes
    Cccam: yes
    Gbox: yes
    Radegast: yes
    Serial: yes
    ConstCW: yes
    Cardreader: yes
    Nagra: yes
    Irdeto: yes
    Conax: yes


    The ecm doublecheck is an interesting feature if you have identical cards. The Dvbapi feature would not be apllicable on a linux build


    Thanks for input oldfart. In the config.sh how do you effectively change the build options? Which parameter/context is edited ?


    Here is the config file at build stage


    #!/bin/bash
    tempfile=/tmp/test$$
    tempfileconfig=/tmp/oscam-config.h
    configfile=oscam-config.h
    DIALOG=${DIALOG:-`which dialog`}


    height=30
    width=65
    listheight=11


    if [ -z '${DIALOG}' ]; then
    echo "Please install dialog package." 1>&2
    exit 1
    fi


    cp -f $configfile $tempfileconfig


    addons="WEBIF HAVE_DVBAPI IRDETO_GUESSING CS_ANTICASC WITH_DEBUG CS_WITH_DOUBLECHECK CS_LED QBOXHD_LED CS_LOGHISTORY MODULE_MONITOR WITH_SSL"
    protocols="MODULE_CAMD33 MODULE_CAMD35 MODULE_CAMD35_TCP MODULE_NEWCAMD MODULE_CCCAM MODULE_GBOX MODULE_RADEGAST MODULE_SERIAL MODULE_CONSTCW"
    readers="WITH_CARDREADER READER_NAGRA READER_IRDETO READER_CONAX READER_CRYPTOWORKS READER_SECA READER_VIACCESS READER_VIDEOGUARD READER_DRE READER_TONGFANG"


    check_test() {
    if [ '$(cat $tempfileconfig | grep '^#define $1$')' != '' ]; then
    echo "on"
    else
    echo "off"
    fi
    }


    disable_all() {
    for i in $1; do
    sed -i -e "s/^#define ${i}$/\/\/#define ${i}/g" $tempfileconfig
    done
    }


    enable_package() {
    for i in $(cat $tempfile); do
    strip=$(echo $i | sed "s/\"//g")
    sed -i -e "s/\/\/#define ${strip}$/#define ${strip}/g" $tempfileconfig
    done
    }


    print_components() {
    clear
    echo "You have selected the following components:"
    echo -e "\nAdd-ons:"
    for i in $addons; do
    printf "\t%-20s: %s\n" $i $(check_test "$i")
    done


    echo -e "\nProtocols:"
    for i in $protocols; do
    printf "\t%-20s: %s\n" $i $(check_test "$i")
    done


    echo -e "\nReaders:"
    for i in $readers; do
    printf "\t%-20s: %s\n" $i $(check_test "$i")
    done
    cp -f $tempfileconfig $configfile
    }


    menu_addons() {
    ${DIALOG} --checklist "\nChoose add-ons:\n " $height $width $listheight \
    WEBIF "Web Interface" $(check_test "WEBIF") \
    HAVE_DVBAPI "DVB API" $(check_test "HAVE_DVBAPI") \
    IRDETO_GUESSING "Irdeto guessing" $(check_test "IRDETO_GUESSING") \
    CS_ANTICASC "Anti cascading" $(check_test "CS_ANTICASC") \
    WITH_DEBUG "Debug messages" $(check_test "WITH_DEBUG") \
    CS_WITH_DOUBLECHECK "ECM doublecheck" $(check_test "CS_WITH_DOUBLECHECK") \
    CS_LED "LED" $(check_test "CS_LED") \
    QBOXHD_LED "QboxHD LED" $(check_test "QBOXHD_LED") \
    CS_LOGHISTORY "Log history" $(check_test "CS_LOGHISTORY") \
    MODULE_MONITOR "Monitor" $(check_test "MODULE_MONITOR") \
    WITH_SSL "OpenSSL support" $(check_test "WITH_SSL") \
    2> ${tempfile}


    opt=${?}
    if [ $opt != 0 ]; then return; fi


    disable_all "$addons"
    enable_package
    }


    menu_protocols() {
    ${DIALOG} --checklist "\nChoose protocols:\n " $height $width $listheight \
    MODULE_CAMD33 "camd 3.3" $(check_test "MODULE_CAMD33") \
    MODULE_CAMD35 "camd 3.5 UDP" $(check_test "MODULE_CAMD35") \
    MODULE_CAMD35_TCP "camd 3.5 TCP" $(check_test "MODULE_CAMD35_TCP") \
    MODULE_NEWCAMD "newcamd" $(check_test "MODULE_NEWCAMD") \
    MODULE_CCCAM "CCcam" $(check_test "MODULE_CCCAM") \
    MODULE_GBOX "gbox" $(check_test "MODULE_GBOX") \
    MODULE_RADEGAST "radegast" $(check_test "MODULE_RADEGAST") \
    MODULE_SERIAL "Serial" $(check_test "MODULE_SERIAL") \
    MODULE_CONSTCW "constant CW" $(check_test "MODULE_CONSTCW") \
    2> ${tempfile}


    opt=${?}
    if [ $opt != 0 ]; then return; fi


    disable_all "$protocols"
    enable_package
    }


    menu_reader() {
    ${DIALOG} --checklist "\nChoose reader:\n " $height $width $listheight \
    READER_NAGRA "Nagravision" $(check_test "READER_NAGRA") \
    READER_IRDETO "Irdeto" $(check_test "READER_IRDETO") \
    READER_CONAX "Conax" $(check_test "READER_CONAX") \
    READER_CRYPTOWORKS "Cryptoworks" $(check_test "READER_CRYPTOWORKS") \
    READER_SECA "Seca" $(check_test "READER_SECA") \
    READER_VIACCESS "Viaccess" $(check_test "READER_VIACCESS") \
    READER_VIDEOGUARD "NDS Videoguard" $(check_test "READER_VIDEOGUARD") \
    READER_DRE "DRE Crypt" $(check_test "READER_DRE") \
    READER_TONGFANG "Tongfang" $(check_test "READER_TONGFANG") \
    2> ${tempfile}


    opt=${?}
    if [ $opt != 0 ]; then return; fi


    menuitem=`cat $tempfile`
    if [ '$menuitem' != '' ]; then
    echo -n " \"WITH_CARDREADER\"" >> ${tempfile}
    fi
    disable_all "$readers"
    enable_package
    }


    while true; do
    ${DIALOG} --menu "\nSelect category:\n " $height $width $listheight \
    Add-ons "Add-ons" \
    Protocols "Network protocols" \
    Reader "Reader" \
    Save "Save" \
    2> ${tempfile}


    opt=${?}
    if [ $opt != 0 ]; then clear; rm $tempfile; rm $tempfileconfig; exit; fi


    menuitem=`cat $tempfile`
    case $menuitem in
    Add-ons) menu_addons;;
    Protocols) menu_protocols;;
    Reader) menu_reader;;
    Save) print_components; rm $tempfile; rm $tempfileconfig; exit;;
    esac
    done



    That is the standard config file but which parameters are amended.


    thanks


    t

    Dont forget to hit the thanks button!!!!!!!!!!!!!



    :41_002:



    Some articles may discuss topics that are illegal, so this information is provided for educational purposes only, your use of the content, downloads and files, or any part thereof, is made solely at your own risk and responsibility. Viewing Pay TV without a valid subscription is illegal. !! Linuxsat-Support.com cannot be held responsible for the content of any information stored or posted on this forum.

  • i've never seen them screens before . Please share your knowledge. I compile over command line there is no gui involved . Would love to know this one as its something new.


    i guess your running oscam in a receiver if you need the dvbapi function


    thx again

    Dont forget to hit the thanks button!!!!!!!!!!!!!



    :41_002:



    Some articles may discuss topics that are illegal, so this information is provided for educational purposes only, your use of the content, downloads and files, or any part thereof, is made solely at your own risk and responsibility. Viewing Pay TV without a valid subscription is illegal. !! Linuxsat-Support.com cannot be held responsible for the content of any information stored or posted on this forum.

  • No - running Oscam on a Linux box running Ubuntu 10.10
    New to Oscam, but when I tried the sky card - it didn't work without dvapi.
    config.sh is part of the svn file, have a look where you unpacked the source code
    (mine is in /usr/local/bin/oscam-svn)
    the config file edits the make files (I think)
    you then have to compile as normal

  • my config file is in usr/src/oscam . Indeed the config files edits the make files . I tried running from root ./config.sh but debian told me to "please install a dialog package"


    so i gave it a bit of apt-get install dialog ....... let it install


    then from my build directory as root i did .... > ./config.sh


    &


    voila


    got the same screens as you posted.


    thanks for this as i could not work out for the life of me how to edit build options from the script context.


    So , note to all . If you want to choose your compile options/addons make sure you have dialog installed on your linux system for a gui easy way .


    Once in the gui you navigate with up,down,esc,enter and use the space bar to toggle options.


    You 100% do not need the dvbapi for your card to read but if it works it works. If it ain't broke don't fix it !


    regards


    t

    Dont forget to hit the thanks button!!!!!!!!!!!!!



    :41_002:



    Some articles may discuss topics that are illegal, so this information is provided for educational purposes only, your use of the content, downloads and files, or any part thereof, is made solely at your own risk and responsibility. Viewing Pay TV without a valid subscription is illegal. !! Linuxsat-Support.com cannot be held responsible for the content of any information stored or posted on this forum.

OSCam Support Forum

Configs, discussion, downloads and guides for OSCam Softcam.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!